DELTA 23347 20950 350
SVN  ³9´!a ˆ' ˜ ‡ˆ"€I ¤2Qt
#include <QTabWidget>class QTreeWidget;
class QDockWidget;
class QStatusBar;
class QMainWindowENDREP
DELTA 23072 1961 77753
SVN  …É5…Î^@ˆ" …p €U Œw†ƒ ­k“ƒ ³Àv€O Ê`ôO€ƒ X‚­@ Â,ƒÁ>€[ à„„: äm„äHQt
#include <QApplication>
#include <QDesktopWidget>
#include <QHeaderView>
#include <QInputDialog>
#include <QMessageBox>
#include <QRadioButton>
#include <QScrollArea>

// utility
#include "support.h"

// client1.01.0#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
    cma_table->horizontalHeader()->setSectionResizeMode(QHeaderView::Stretch);
#else
    cma_table->horizontalHeader()->setResizeMode(QHeaderView::Stretch);
#endif
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
    qlt[i]->setText(QString::fromLatin1(buf[2*i]));
#else
    qlt[i]->setText(QString::fromAscii(buf[2*i]));
#endif
    if (j != GROWTH && j != GRANARY && j!= WASTE && j!= CORRUPTION){
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
      qlt[i]->setToolTip(QString::fromLatin1(buf[2*i + 1]));
#else
      qlt[i]->setToolTip(QString::fromAscii(buf[2*i + 1]));
#endif
    }#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
  const QString title = QString::fromUtf8(_("Buy")) + QString::fromLatin1(" ? ");
#else
  const QString title = QString::fromUtf8(_("Buy")) + QString::fromAscii(" ? ");
#endifENDREP
DELTA 23072 79744 21540
SVN  âzãGH …p €H Ý…kQt
#include <QApplication>
#include <QHeaderView>
#include <QMessageBox>ENDREP
DELTA 23072 101314 20660
SVN  ÇLÈW …o € Áb…jQt
#include <QColorDialog>
#include <QComboBox>
#include <QFontDialog>
#include <QLineEdit>
#include <QScrollArea>
#include <QSpinBox>ENDREP
DELTA 23541 0 1144
SVN  ‚ä<‚çƒk …b €‚ ‚£"†6€[ º‚ª% Qt
#include <QAction>
#include <QApplication>
#include <QDockWidget>
#include <QHeaderView>
#include <QLineEdit>
#include <QTableWidget>
#include <QTextEdit>
#include <QTreeWidget>

// common
#include "game.h"
#include "version.h"

// client
#include "client_main.h"

// #if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
  start_players_tree->header()->setSectionResizeMode(QHeaderView::ResizeToContents);
#else
  start_players_tree->header()->setResizeMode(QHeaderView::ResizeToContents);
#endifENDREP
DELTA 23053 61261 34828
SVN  ‚ÇW‚ÈpF‚ …p €$ ¼|…k <Âi… ‚?Ä* µzÆk ‚8üi„ /ÿ% 
ŽV€I R‚­?¡ Xîu ¾/Ÿz„ é*Þ-Qt
#include <QApplication>
#include <QComboBox>
#include <QHeaderView>
#include <QMessageBox>
#include <QProgressBar>
#include <QScrollArea>
#include <QTableWidget>falsetrue unit_list_iterate_end;
  } players_iterate_end;
  return best_candidate;Action for button 'find units' intrueENDREP
DELTA 18893 18501 2419
SVN  »F„K‡^ƒO …X €‘7 M@¤ Kµ €©$ O‘?˜ I¶€L O‘?ª Kµ €ˆw O‘?¿ Kµ €‰~ O‘?— Kµ €‚k O‘?˜ Kµ €‚ O‘?€X Kµ €…c O‘?š I¶€‡o O‘? I¶€‚< O‘?š I¶€† S‘?€A Rµ €@ S‘?µ Rµ €x S‘?² S´€T O‘?¨ Kµ €K O‘?€L Kµ €I O‘?¶ Kµ · O‘?– Kµ €0 R‘? ‡p‡'€9 R‘?¡ V´€k ‚,‘?€X R‘? ”I€ R‘?Š ”P€B R‘? ‚–e² Hµ~ 7™8€„^ O‘?› H· €ƒ' O‘?™ I¶€ O‘?š I¶€. O‘?ž I¶€„ O‘? I¶€1 O‘?œ I¶€G O‘?Ÿ I¶€, O‘?¥ I¶€S O‘?§ I¶€P O‘?¯ I¶€ O‘?´ Kµ ¿ G €Q Kµ €" G  ‚>›P€m R‘?  Ÿ%„ O´~€A R‘? a¢"€¡ K‘?¬ H´€ƒ> O‘?  I¶€‚r O‘?£ I¶€‚ O‘?© I¶€‹ O‘?¦ I¶€ƒ2 O‘?¬ I¶€ƒ O‘?¢ I¶€‚N O‘?§ I¶€‚v O‘?¦ I¶€‚~ O‘?ž I¶€ƒ O‘?© I¶€‚x O‘?£ I¶€‚t O‘?¯ I¶€ƒj O‘?¯ I¶€ƒj R‘? ^¤l€? R‘? \§(€‹S O‘? I¶€ƒ O‘?§ I¶€ƒ9 R‘? V©b€ˆK R‘? L¬€…@ O‘?· L´€‡< R‘? R¯¤ E‘?¸ d¯9€V R‘? v±5† R‘? r´€9 E‘? 6¶F€x E‘? Q¶v€^ E‘? º6€‡u E‘?Ÿ C´³ E‘?œ C´© W¨~¡ Bµ €† E‘? Bµ €… A  Bµ €S E‘?µ Bµ €”v E‘?¬ Bµ €„\ E‘?€d Bµ €ƒ E‘?™ Bµ €Œ A § Bµ € E‘?€w Bµ £ E‘?œ Bµ €‚X E‘?¤ Bµ €ƒ O‘?¤ I¶€? O‘?¤ I¶€C O‘?” I¶€_ O‘?” I¶€Vfc_config.h>
#endif

// Qt
#include <QComboBox>
#include <QHeaderView>
#include <QMessageBox>
#include <QRadioButton>
#include <QTableWidgetItem>
#include <QTextEdit>
#include <QToolBox>

// utility
#include "astring.h"

// common
#include "actions.h"
#include "city.h"
#include "game.h"
#include "government.h"
#include "improvement.h"
#include "movement.h"
#include "nation.h"

// client
#include "control.h"
#include "helpdata.h"
#include "text.h"

#include "packhand.h"
#include "tilespec.h"

// gui-qt
#include "dialogs.h"
#include "qtg_cxxside.h"
#include "sprite.h"

static void diplomat_keep_moving_unit(QVariant data1, QVariant data2);
static void diplomat_keep_moving_city(QVariant data1, QVariant data2);
static void diplomat_incite(QVariant data1, QVariant data2);
static void spy_request_sabotage_list(QVariant data1, QVariant data2);
static void spy_sabotage(QVariant data1, QVariant data2);
static void spy_steal(QVariant data1, QVariant data2);
static void spy_steal_something(QVariant data1, QVariant data2);
static void diplomat_steal(QVariant data1, QVariant data2);
static void spy_poison(QVariant data1, QVariant data2);
static void diplomat_embassy(QVariant data1, QVariant data2);
static void spy_sabotage_unit(QVariant data1, QVariant data2);
static void diplomat_investigate(QVariant data1, QVariant data2);
static void diplomat_sabotage(QVariant data1, QVariant data2);
static void diplomat_bribe(QVariant data1, QVariant data2);
static void caravan_establish_trade(QVariant data1, QVariant data2);
static void caravan_help_build(QVariant data1, QVariant data2);
static void keep_moving(QVariant data1, QVariant data2);
static void caravan_keep_moving(QVariant data1, QVariant data2);
static void pillage_something(QVariant data1, QVariant data2);
static void action_entry(choice_dialog *cd, enum mk_eval_result state,
                         QString title, pfcn_void func, QVariant data1,
                         QVariant data2);

static int caravan_city_id = 0;
static int caravan_unit_id = 0;
static bool caravan_dialog_open = false;
static bool is_showing_pillage_dialog = false;
static choice_dialog *caravan_dialog = NULL;
static races_dialog* race_dialog;
static bool is_race_dialog_open = false;*
 Constructor for selecting nations*/
races_dialog::races_dialog(struct player *pplayer, QWidget * parent):QDialog(parent)
{
  struct nation_group *group;
  int i;
  QGridLayout *qgroupbox_layout;
  QGroupBox *no_name;
  QWidget *tab_widget;
  QTableWidgetItem *item;
  QPixmap *pix;
  QHeaderView *header;
  QSize size;
  QString title;

  setAttribute(Qt::WA_DeleteOnClose);
  is_race_dialog_open = true;
  main_layout = new QGridLayout;
  nation_tabs = new QToolBox(parent);
  selected_nation_tabs = new QTableWidget;
  city_styles = new QTableWidget;
  ok_button = new QPushButton;
  tplayer = pplayer;

  selected_nation = -1;
  selected_style = -1;
  selected_sex = -1;
  setWindowTitle(_("Select Nation"));
  selected_nation_tabs->setRowCount(0);
  selected_nation_tabs->setColumnCount(1);
  selected_nation_tabs->setSelectionMode(QAbstractItemView::SingleSelection);
  selected_nation_tabs->verticalHeader()->setVisible(false);
  selected_nation_tabs->horizontalHeader()->setVisible(false);
  selected_nation_tabs->setProperty("showGrid", "true");
  selected_nation_tabs->setEditTriggers(QAbstractItemView::NoEditTriggers);

  city_styles->setRowCount(0);
  city_styles->setColumnCount(2);
  city_styles->setSelectionMode(QAbstractItemView::SingleSelection);
  city_styles->verticalHeader()->setVisible(false);
  city_styles->horizontalHeader()->setVisible(false);
  city_styles->setProperty("showGrid", "false");
  city_styles->setProperty("selectionBehavior", "SelectRows");
  city_styles->setEditTriggers(QAbstractItemView::NoEditTriggers);

  qgroupbox_layout = new QGridLayout;
  no_name = new QGroupBox(parent);
  leader_name = new QComboBox(no_name);
  is_male = new QRadioButton(no_name);
  is_female = new QRadioButton(no_name);

  leader_name->setEditable(true);
  qgroupbox_layout->addWidget(leader_name, 1, 0, 1, 2);
  qgroupbox_layout->addWidget(is_male, 2, 1);
  qgroupbox_layout->addWidget(is_female, 2, 0);
  is_female->setText(_("Female"));
  is_male->setText(_("Male"));
  no_name->setLayout(qgroupbox_layout);

  description = new QTextEdit;
  description->setReadOnly(true);
  description->setText(_("Choose nation"));
  no_name->setTitle(_("Your leader name"));

  /**
   * Fill city styles, no need to update them later
   */

  for (i = 0; i < game.control.styles_count; i++) {
    if (city_style_has_requirements(&::city_styles[i])) {
      continue;
    }
    item = new QTableWidgetItem;
    city_styles->insertRow(i);
    pix = get_sample_city_sprite(tileset, i)->pm;
    item->setData(Qt::DecorationRole, *pix);
    item->setData(Qt::UserRole, i);
    size.setWidth(pix->width());
    size.setHeight(pix->height());
    item->setSizeHint(size);
    city_styles->setItem(i, 0, item);
    item = new QTableWidgetItem;
    item->setText(city_style_name_translation(i));
    city_styles->setItem(i, 1, item);
  }
  header = city_styles->horizontalHeader();
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
  header->setSectionResizeMode(QHeaderView::Stretch);
#else
  header->setResizeMode(QHeaderView::Stretch);
#endif
  header->resizeSections(QHeaderView::ResizeToContents);
  header = city_styles->verticalHeader();
  header->resizeSections(QHeaderView::ResizeToContents);
  tab_widget = new QWidget();
  nation_tabs->addItem(tab_widget, _("All Nations"));
  for (i = 0; i < nation_group_count(); i++) {
    group = nation_group_by_number(i);
    tab_widget = new QWidget();
    nation_tabs->addItem(tab_widget, nation_group_name_translation(group));
  }
  connect(nation_tabs, SIGNAL(currentChanged(int)), SLOT(set_index(int)));
  connect(city_styles->selectionModel(),
          SIGNAL(selectionChanged(const QItemSelection &,
                                  const QItemSelection &)),
          SLOT(style_selected(const QItemSelection &,
                              const QItemSelection &)));
  connect(selected_nation_tabs->selectionModel(),
          SIGNAL(selectionChanged(const QItemSelection &,
                                  const QItemSelection &)),
          SLOT(nation_selected(const QItemSelection &,
                              const QItemSelection &)));
  connect(leader_name, SIGNAL(currentIndexChanged(int)),
          SLOT(leader_selected(int)));

  ok_button = new QPushButton;
  ok_button->setText(_("Cancel"));
  connect(ok_button, SIGNAL(pressed()), SLOT(cancel_pressed()));
  main_layout->addWidget(ok_button, 8, 1, 1, 1);
  random_button = new QPushButton;
  random_button->setText(_("Random"));
  connect(random_button, SIGNAL(pressed()), SLOT(random_pressed()));
  main_layout->addWidget(random_button, 8, 0, 1, 1);
  ok_button = new QPushButton;
  ok_button->setText(_("Ok"));
  connect(ok_button, SIGNAL(pressed()), SLOT(ok_pressed()));
  main_layout->addWidget(ok_button, 8, 2, 1, 1);
  main_layout->addWidget(no_name, 0, 2, 2, 1);
  main_layout->addWidget(nation_tabs, 0, 0, 6, 1);
  main_layout->addWidget(city_styles, 2, 2, 4, 1);
  main_layout->addWidget(description, 6, 0, 2, 3);
  main_layout->addWidget(selected_nation_tabs, 0, 1, 6, 1);

  setLayout(main_layout);
  set_index(0);
  update();

  if (C_S_RUNNING == client_state()) {
    title = _("Edit Nation");
  } else if (NULL != pplayer && pplayer == client.conn.playing) {
    title = _("What Nation Will You Be?");
  } else {
    title = _("Pick Nation");
  }

  setWindowTitle(title);*
  Destructor for races**********/
races_dialog::~races_dialog()
{
  ::is_race_dialog_open = false;*
  Sets new nations' group by given index*/
void races_dialog::set_index(int index)
{
  QTableWidgetItem *item;
  QPixmap *pix;
  struct nation_group *group;
  int i = 0;
  struct sprite *s;
  QHeaderView *header;

  selected_nation_tabs->clearContents();
  selected_nation_tabs->setRowCount(0);

  group = nation_group_by_number(index - 1);
  nations_iterate(pnation) {
    if (!is_nation_playable(pnation) || !pnation->is_available) {
      continue;
    }
    if (!nation_is_in_group(pnation, group) && index != 0) {
      continue;
    }
    item = new QTableWidgetItem;
    selected_nation_tabs->insertRow(i);
    s = get_nation_flag_sprite(tileset, pnation);
    pix = s->pm;
    item->setData(Qt::DecorationRole, *pix);
    item->setData(Qt::UserRole, nation_number(pnation));
    item->setText(nation_adjective_translation(pnation));
    selected_nation_tabs->setItem(i, 0, item);
  } nations_iterate_end;

  selected_nation_tabs->sortByColumn(0, Qt::AscendingOrder);
  header = selected_nation_tabs->horizontalHeader();
  header->resizeSections(QHeaderView::Stretch);
  header = selected_nation_tabs->verticalHeader();
  header->resizeSections(QHeaderView::ResizeToContents);*
  Sets selected nation and updates style and leaders selector*/
void races_dialog::nation_selected(const QItemSelection &selected,
                                   const QItemSelection &deselcted)
{
  char buf[4096];
  QModelIndex index ;
  QVariant qvar,qvar2;
  QModelIndexList indexes = selected.indexes();
  QString str;
  QTableWidgetItem *item;
  int style, ind;

  if (indexes.isEmpty()) {
    return;
  }

  index = indexes.at(0);
  if (indexes.isEmpty()){
    return;
  }
  qvar = index.data(Qt::UserRole);
  selected_nation = qvar.toInt();

  helptext_nation(buf, sizeof(buf), nation_by_number(selected_nation), NULL);
  description->setText(buf);
  leader_name->clear();
  nation_leader_list_iterate(nation_leaders(nation_by_number
                                            (selected_nation)), pleader) {
    str = QString::fromUtf8(nation_leader_name(pleader));
    leader_name->addItem(str, nation_leader_is_male(pleader));
  } nation_leader_list_iterate_end;

  /**
   * select style for nation
   */

  style = city_style_of_nation(nation_by_number(selected_nation));
  qvar = qvar.fromValue<int>(style);
  item = new QTableWidgetItem;

  for (ind = 0; ind < city_styles->rowCount(); ind++) {
    item = city_styles->item(ind, 0);

    if (item->data(Qt::UserRole) == qvar) {
      city_styles->selectRow(ind);
    }
  }*
  Sets selected style*/
void races_dialog::style_selected(const QItemSelection &selected,
                                   const QItemSelection &deselcted)
{
  QModelIndex index ;
  QVariant qvar;
  QModelIndexList indexes = selected.indexes();

  if (indexes.isEmpty()) {
    return;
  }

  index = indexes.at(0);
  qvar = index.data(Qt::UserRole);
  selected_style = qvar.toInt();*
  Sets selected leader*/
void races_dialog::leader_selected(int index)
{
  if (leader_name->itemData(index).toBool())
  {
    is_male->setChecked(true);
    is_female->setChecked(false);
    selected_sex=0;
  } else {
    is_male->setChecked(false);
    is_female->setChecked(true);
    selected_sex=1;
  }*
  Button accepting all selection has been pressed, closes dialog if
  everything is ok*/
void races_dialog::ok_pressed()
{

  if (selected_nation == -1) {
    return;
  }

  if (selected_sex == -1) {
    output_window_append(ftc_client, _("You must select your sex."));
    return;
  }

  if (selected_style == -1) {
    output_window_append(ftc_client, _("You must select your city style."));
    return;
  }

  if (leader_name->currentText().length() == 0) {
    output_window_append(ftc_client, _("You must type a legal name."));
    return;
  }
  dsend_packet_nation_select_req(&client.conn, player_number(tplayer),
                                 selected_nation, selected_sex,
                                 leader_name->currentText().toUtf8().data(),
                                 selected_style);
  delete this;*
  Constructor for notify**********/
notify_dialog::notify_dialog(const char *caption, const char *headline, 
                             const char *lines, QWidget *parent)
                             : fcwidget()
{
  int x, y;
  QString qlines;

  setCursor(Qt::ArrowCursor);
  setParent(parent);
  setFrameStyle(QFrame::Box);
  setWindowOpacity(0.5);
  cw = new close_widget(this);
  cw->put_to_corner();

#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
  qcaption = QString::fromLatin1(caption);
  qheadline = QString::fromLatin1(headline);
  qlines = QString::fromLatin1(lines);
#else
  qcaption = QString::fromAscii(caption);
  qheadline = QString::fromAscii(headline);
  qlines = QString::fromAscii(lines);
#endif
  qlist = qlines.split("\n");
  small_font =::gui()->fc_fonts.get_font("gui_qt_font_notify_label");
  x = 0;
  y = 0;
  calc_size(x, y);
  resize(x, y);
  gui()->mapview_wdg->find_place(gui()->mapview_wdg->width() - x - 4, 4,
                                 x, y, x, y, 0);
  move(x, y);
  was_destroyed = false;*
  Calculates size of notify**********/
void notify_dialog::calc_size(int &x, int &y)
{
  QFontMetrics fm(*small_font);
  int i;
  QStringList str_list;

  str_list = qlist;
  str_list << qcaption << qheadline;

  for (i = 0; i < str_list.count(); i++) {
    x = qMax(x, fm.width(str_list.at(i)));
    y = y + 3 + fm.height();
  }
  x = x + 15;*
  Paint Event for notify**********/
void notify_dialog::paintEvent(QPaintEvent * paint_event)
{
  QPainter painter(this);
  QPainterPath path;
  QPen pen;
  QFontMetrics fm(*small_font);
  int i;

  pen.setWidth(1);
  pen.setColor(QColor(232, 255, 0));
  painter.setBrush(QColor(0, 0, 0, 175));
  painter.drawRect(0, 0, width(), height());
  painter.setFont(*small_font);
  painter.setPen(pen);
  painter.drawText(10, fm.height() + 3, qcaption);
  painter.drawText(10, 2 * fm.height() + 6, qheadline);
  for (i = 0; i < qlist.count(); i++) {
    painter.drawText(10, 3 + (fm.height() + 3) * (i + 3), qlist[i]);
  }
  painter.drawLine(0,0,width(),0);
  painter.drawLine(0,height()-1,width(),height()-1);
  painter.drawLine(0,0,0,height());
  painter.drawLine(width()-1,0,width()-1,height());
  cw->put_to_corner();alled when mouse button was pressed, just to close on right clicknotify_dialog::mousePressEvent(QMouseEvent *event)
{
  cursor = event->globalPos() - geometry().topLeft();
  if (event->button() == Qt::RightButton){
    was_destroyed = true;
    close();
  }alled when mouse button was pressed and moving aroundnotify_dialog::mouseMoveEvent(QMouseEvent *event)
{
  move(event->globalPos() - cursor);
  setCursor(Qt::SizeAllCursor);alled when mouse button unpressed. Restores cursornotify_dialog::mouseReleaseEvent(QMouseEvent *event)
{
  setCursor(Qt::ArrowCursor);*
  Called when close button was pressed*/
void notify_dialog::update_menu()
{
  was_destroyed = true;
  destroy();*
  Destructor for notify dialog, notice that somehow object is not destroyed
  immediately, so it can be still visible for parent, check boolean
  was_destroyed if u suspect it could not be destroyed yet*/
notify_dialog::~notify_dialog()
{
  was_destroyed = true;
  destroy();*
  Button canceling all selections has been pressed. */
void races_dialog::cancel_pressed()
{
  delete this;*
  Sets random nation*/
void races_dialog::random_pressed()
{
  dsend_packet_nation_select_req(&client.conn,player_number(tplayer),-1,
                                 false, "", 0);
  delete this;                         const char *lines)
{
  notify_dialog *nd = new notify_dialog(caption, headline, lines,
                                       gui()->mapview_wdg);
  nd->show();Popup the nation selection dialogup_races_dialog(struct player *pplayer)
{
  race_dialog = new races_dialog(pplayer);
  race_dialog->show();if (is_race_dialog_open){
    race_dialog->close();
    is_race_dialog_open = false;
  }unit_select_dialog_popup(struct tile *ptile)
{
  if(ptile != NULL && unit_list_size(ptile->units) > 1){
    gui()->toggle_unit_sel_widget(ptile);
  }Update theunit_select_dialog_update_real(void)
{
  gui()->update_unit_sel();  /* maybe just emit signal about chosen toolbox ?struct government *government)
{
  QMessageBox ask(gui()->central_wdg);
  int ret;

  if (0 > client.conn.playing->revolution_finishes) {
    ask.setText(_("You say you wanna revolution?"));
    ask.setStandardButtons(QMessageBox::Cancel | QMessageBox::Ok);
    ask.setDefaultButton(QMessageBox::Cancel);
    ask.setIcon(QMessageBox::Warning);
    ask.setWindowTitle(_("Revolution!"));
    ret = ask.exec();

    switch (ret) {
    case QMessageBox::Cancel:
      break;
    case QMessageBox::Ok:
      revolution_response(government);
      break;
    }
  } else {
    revolution_response(government);
  }*
  Constructor for choice_**********/
choice_dialog::choice_dialog(const QString title, const QString text,
                             QWidget *parent): QWidget(parent)
{
  QLabel *l = new QLabel(text);

  signal_mapper = new QSignalMapper(this);
  layout = new QVBoxLayout(this);

  layout->addWidget(l);
  setWindowFlags(Qt::Dialog);
  setWindowTitle(title);
  setAttribute(Qt::WA_DeleteOnClose);
  gui()->set_diplo_dialog(this);
  unit_id = -1;*
  Destructor for choice**********/
choice_dialog::~choice_dialog()
{
  data1_list.clear();
  data2_list.clear();
  delete signal_mapper;
  gui()->set_diplo_dialog(NULL);
*
  Sets layout for choice**********/
void choice_dialog::set_layout()
{
  connect(signal_mapper, SIGNAL(mapped(const int &)),
           this, SLOT(execute_action(const int &)));
  setLayout(layout);*
  Adds new action for choice**********/
void choice_dialog::add_item(QString title, pfcn_void func, QVariant data1,
                             QVariant data2, bool warn)
{
   QPushButton *button = new QPushButton(title);
   connect(button, SIGNAL(clicked()), signal_mapper, SLOT(map()));
   signal_mapper->setMapping(button, func_list.count());
   func_list.append(func);
   data1_list.append(data1);
   data2_list.append(data2);

   if (warn) {
     button->setToolTip(QString(_("Starting to do this"
                                  " may currently be impossible.")));
     button->setIcon(QIcon::fromTheme("dialog-warning"));
   }

   layout->addWidget(button);*
  Shows choice**********/
void choice_dialog::show_me()
{
  QPoint p;

  p = mapFromGlobal(QCursor::pos());
  p.setY(p.y()-this->height());
  p.setX(p.x()-this->width());
  move(p);
  show();*
  Returns layout in choice**********/
QVBoxLayout *choice_dialog::get_layout()
{
  return layout;*
  Run chosen action and close**********/
void choice_dialog::execute_action(const int action)
{
  pfcn_void func = func_list.at(action);
  func(data1_list.at(action), data2_list.at(action));
  close();*
  Action establish trade for choice**********/
static void caravan_establish_trade(QVariant data1, QVariant data2)
{
  dsend_packet_unit_establish_trade(&client.conn, data2.toInt());
  caravan_dialog_open = false;
  process_caravan_arrival(NULL);*
  Action help build wonder for choice**********/
static void caravan_help_build(QVariant data1, QVariant data2)
{
  dsend_packet_unit_help_build_wonder(&client.conn, data2.toInt());
  caravan_dialog_open = false;
  process_caravan_arrival(NULL);*
  Action 'do nothing' with caravan for choice**********/
static void caravan_keep_moving(QVariant data1, QVariant data2)
{
  caravan_dialog_open = false;
  process_caravan_arrival(NULL);*
  Empty action for choice dialog (just do nothing)*/
static void keep_moving(QVariant data1, QVariant data2)
{
}
*****
  Starts revolution with targeted government as target or anarchy otherwise*/
void revolution_response(struct government *government)
{
  if (!government) {
    start_revolution();
  } else {
    set_government_choice(government);
  }
}
                          struct city *phomecity, struct city *pdestcity)
{
  char title_buf[128], buf[128], buf2[1024];
  bool can_establish, can_trade, can_wonder;
  struct city* destcity;
  struct unit* caravan;
  QString wonder;
  QString str;
  QVariant qv1, qv2;
  pfcn_void func;

  fc_snprintf(title_buf, sizeof(title_buf),
              /* TRANS: %s is a unit type */
              _("Your %s Has Arrived"), unit_name_translation(punit));
  fc_snprintf(buf, sizeof(buf),
              _("Your %s from %s reaches the city of %s.\nWhat now?"),
              unit_name_translation(punit),
              city_name(phomecity), city_name(pdestcity));

  caravan_dialog = new choice_dialog(QString(title_buf),
                                     QString(buf),
                                     gui()->game_tab_widget);
  caravan_dialog_open = true;
  qv1 = pdestcity->id;
  qv2 = punit->id;
  caravan_city_id = pdestcity->id;
  caravan_unit_id = punit->id;
  can_trade = can_cities_trade(phomecity, pdestcity);
  can_establish = can_trade
                  && can_establish_trade_route(phomecity, pdestcity);
  destcity = game_city_by_number(pdestcity->id);
  caravan = game_unit_by_number(punit->id);

  if (destcity && caravan && unit_can_help_build_wonder(caravan, destcity)) {
    can_wonder = true;
    fc_snprintf(buf2, sizeof(buf2), _("Help build _Wonder (%d remaining)"),
                impr_build_shield_cost(destcity->production.value.building)
                - destcity->shield_stock);
    wonder = QString(buf2);
  } else {
    can_wonder = false;
    wonder = QString(_("Help build _Wonder"));
  }

  if (can_trade) {
    func = caravan_establish_trade;
    str = can_establish ? QString(_("Establish _Trade route")) :
          QString(_("Enter Marketplace"));
    caravan_dialog->add_item(str, func, qv1, qv2, FALSE);
  }
  if (can_wonder) {
    func = caravan_help_build;
    caravan_dialog->add_item(wonder, func, qv1, qv2, FALSE);
  }
  func = caravan_keep_moving;
  caravan_dialog->add_item(QString(_("Keep moving")),
                           func, qv1, qv2, FALSE);

  caravan_dialog->set_layout();
  caravan_dialog->show_me();falsbool caravan_dialog_is_open(int *unit_id, int *city_id)
{
  if (unit_id) {
    *unit_id = caravan_unit_id;
  }
  if (city_id) {
    *city_id = caravan_city_id;
  }
  return caravan_dialog_open;dest_tile)
{
  struct city *pcity;
  struct unit *ptunit;
  struct astring title = ASTRING_INIT, text = ASTRING_INIT;
  int diplomat_id;
  int diplomat_target_id;
  QVariant qv1, qv2;
  pfcn_void func;

  astr_set(&title,
           /* TRANS: %s is a unit name, e.g., Spy */
           _("Choose Your %s's Strategy"), unit_name_translation(punit));
  astr_set(&text,
           /* TRANS: %s is a unit name, e.g., Diplomat, Spy */
           _("Your %s is waiting for your command."),
           unit_name_translation(punit));
  choice_dialog *cd = new choice_dialog(astr_str(&title),
                                                 astr_str(&text),
                                                 gui()->game_tab_widget);
  diplomat_id = punit->id;
  qv1 = punit->id;
  cd->unit_id = diplomat_id;

  if ((pcity = tile_city(dest_tile))) {
    /* Spy/Diplomat acting against a city */
    diplomat_target_id = pcity->id;
    gui()->set_current_unit(diplomat_id, diplomat_target_id, ATK_CITY);
    qv2 = pcity->id;

    action_entry(cd,
                 action_enabled_unit_on_city_local(
                   ACTION_ESTABLISH_EMBASSY, punit, pcity),
                 QString(_("Establish _Embassy")),
                 diplomat_embassy, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(
                   ACTION_SPY_INVESTIGATE_CITY, punit, pcity),
                 QString(_("Investigate City")),
                 diplomat_investigate, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(ACTION_SPY_POISON,
                                                   punit, pcity),
                 QString(_("Poison City")), spy_poison, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(
                   ACTION_SPY_SABOTAGE_CITY, punit, pcity),
                 QString(_("_Sabotage City")),
                 diplomat_sabotage, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(
                   ACTION_SPY_TARGETED_SABOTAGE_CITY, punit, pcity),
                 QString(_("Industrial Sabotage")),
                 spy_request_sabotage_list, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(ACTION_SPY_STEAL_TECH,
                                                   punit, pcity),
                 QString(_("Steal Technology")),
                 diplomat_steal, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(
                   ACTION_SPY_TARGETED_STEAL_TECH, punit, pcity),
                 QString(_("Industrial espionage")),
                 spy_steal, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_city_local(ACTION_SPY_INCITE_CITY,
                                                   punit, pcity),
                 QString(_("Incite a Revolt")),
                 diplomat_incite, qv1, qv2);
  }

  if ((ptunit = unit_list_get(dest_tile->units, 0))) {
    /* Spy/Diplomat acting against a unit */

    diplomat_target_id = ptunit->id;    
    gui()->set_current_unit(diplomat_id, diplomat_target_id, ATK_UNIT);
    qv2 = ptunit->id;

    action_entry(cd,
                 action_enabled_unit_on_unit_local(ACTION_SPY_BRIBE_UNIT,
                                                   punit, ptunit),
                 QString(_("Bribe Enemy Unit")),
                 diplomat_bribe, qv1, qv2);

    action_entry(cd,
                 action_enabled_unit_on_unit_local(
                   ACTION_SPY_SABOTAGE_UNIT, punit, ptunit),
                 QString(_("Sabotage Enemy Unit")),
                 spy_sabotage_unit, qv1, qv2);
  }

  if (pcity) {
    qv2 = pcity->id;
  } else {
    qv2 = ptunit->id;
  }

  if (diplomat_can_do_action(punit, DIPLOMAT_MOVE, dest_tile)) {
    if (pcity) {
      func = diplomat_keep_moving_city;
      cd->add_item(QString(_("Keep moving")), func, qv1, qv2, FALSE);
    } else {
      func = diplomat_keep_moving_unit;
      cd->add_item(QString(_("Keep moving")), func, qv1, qv2, FALSE);
    }
  }

  func = keep_moving;
  cd->add_item(QString(_("Do nothing")), func, qv1, qv2, FALSE);

  cd->set_layout();
  cd->show_me();

  astr_free(&title);
  astr_free(&text);
  Show the user the action if it is enabled/
static void action_entry(choice_dialog *cd, enum mk_eval_result state,
                         QString title, pfcn_void func, QVariant data1,
                         QVariant data2)
{
  switch (state) {
  case MKE_FALSE:
    /* Don't even show disabled actions */
    break;
  case MKE_UNCERTAIN:
    cd->add_item(title, func, data1, data2, TRUE);
    break;
  case MKE_TRUE:
    cd->add_item(title, func, data1, data2, FALSE);
    break;
  }*
  Action bribe unit for choice**********/
static void diplomat_bribe(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_unit_by_number(diplomat_target_id)) {
    request_diplomat_answer(DIPLOMAT_BRIBE, diplomat_id,
                            diplomat_target_id, 0);
  }*
  Action sabotage unit for choice**********/
static void spy_sabotage_unit(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  request_diplomat_action(SPY_SABOTAGE_UNIT, diplomat_id,
                          diplomat_target_id, 0);*
  Action steal tech with spy for choice**********/
static void spy_steal(QVariant data1, QVariant data2)
{
  QString str;
  QVariant qv1, qv2;
  pfcn_void func;
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();
  struct city *pvcity = game_city_by_number(diplomat_target_id);
  struct player *pvictim = NULL;
  choice_dialog *cd;
  int nr = 0;

  if (pvcity) {
    pvictim = city_owner(pvcity);
  }
  cd = gui()->get_diplo_dialog();
  if (cd != NULL) {
    cd->close();
  }
  struct astring stra = ASTRING_INIT;
  cd = new choice_dialog(_("_Steal"), _("Steal Technology"),
                         gui()->game_tab_widget);
  qv1 = data1;
  struct player *pplayer = client.conn.playing;
  if (pvictim) {
    advance_index_iterate(A_FIRST, i) {
      if (player_invention_state(pvictim, i) == TECH_KNOWN &&
          (player_invention_state(pplayer, i) == TECH_UNKNOWN ||
           player_invention_state(pplayer, i) == TECH_PREREQS_KNOWN)) {
        func = spy_steal_something;
        str = advance_name_for_player(client.conn.playing, i);
        cd->add_item(str, func, qv1, i, FALSE);
        nr++;
      }
    } advance_index_iterate_end;
    astr_set(&stra, _("At %s's Discretion"),
             unit_name_translation(game_unit_by_number(diplomat_id)));
    func = spy_steal_something;
    str = astr_str(&stra);
    cd->add_item(str, func, qv1, A_UNSET, FALSE);
    cd->set_layout();
    cd->show_me();
  }
  astr_free(&stra);*
  Action steal given tech for choice**********/
static void spy_steal_something(QVariant data1, QVariant data2)
{
  int diplomat_id;
  int diplomat_target_id;

  gui()->get_current_unit(&diplomat_id, &diplomat_target_id, ATK_CITY);
  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_action(DIPLOMAT_STEAL_TARGET, diplomat_id,
                            diplomat_target_id, data2.toInt());
  }*
  Action  request sabotage list for choice**********/
static void spy_request_sabotage_list(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_answer(DIPLOMAT_SABOTAGE_TARGET, diplomat_id,
                            diplomat_target_id, 0);
  }*
  Action  poison city for choice**********/
static void spy_poison(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_action(SPY_POISON, diplomat_id, diplomat_target_id, 0);
  }*
  Action establish embassy for choice**********/
static void diplomat_embassy(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_action(DIPLOMAT_EMBASSY, diplomat_id,
                            diplomat_target_id, 0);
  }*
  Action investigate city for choice**********/
static void diplomat_investigate(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_city_by_number(diplomat_target_id)
      && NULL != game_unit_by_number(diplomat_id)) {
    request_diplomat_action(DIPLOMAT_INVESTIGATE, diplomat_id,
                            diplomat_target_id, 0);
  }*
  Action sabotage for choice**********/
static void diplomat_sabotage(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_action(DIPLOMAT_SABOTAGE, diplomat_id,
                            diplomat_target_id, B_LAST + 1);
  }*
  Action steal with diplomat for choice**********/
static void diplomat_steal(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_action(DIPLOMAT_STEAL, diplomat_id,
                            diplomat_target_id, A_UNSET);
  }*
  Action incite revolt for choice**********/
static void diplomat_incite(QVariant data1, QVariant data2)
{
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if (NULL != game_unit_by_number(diplomat_id)
      && NULL != game_city_by_number(diplomat_target_id)) {
    request_diplomat_answer(DIPLOMAT_INCITE, diplomat_id,
                            diplomat_target_id, 0);
  }*
  Action keep moving with diplomat for choice**********/
static void diplomat_keep_moving_city(QVariant data1, QVariant data2)
{
  struct unit *punit;
  struct city *pcity;
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if ((punit = game_unit_by_number(diplomat_id))
      && (pcity = game_city_by_number(diplomat_target_id))
      && !same_pos(unit_tile(punit), city_tile(pcity))) {
    request_diplomat_action(DIPLOMAT_MOVE, diplomat_id,
                            diplomat_target_id, ATK_CITY);
  }*
  Action keep moving with diplomat for choice**********/
static void diplomat_keep_moving_unit(QVariant data1, QVariant data2)
{
  struct unit *punit;
  struct unit *tunit;
  int diplomat_id = data1.toInt();
  int diplomat_target_id = data2.toInt();

  if ((punit = game_unit_by_number(diplomat_id))
      && (tunit = game_unit_by_number(diplomat_target_id))
      && !same_pos(unit_tile(punit), unit_tile(tunit))) {
    request_diplomat_action(DIPLOMAT_MOVE, diplomat_id,
                            diplomat_target_id, ATK_UNIT);
  }char buf[1024];
  char buf2[1024];
  int ret;
  int diplomat_id;
  int diplomat_target_id;

  fc_snprintf(buf, ARRAY_SIZE(buf), PL_("Treasury contains %d gold.",
                                        "Treasury contains %d gold.",
                                        client_player()->economic.gold),
              client_player()->economic.gold);

  if (INCITE_IMPOSSIBLE_COST == cost) {
    QMessageBox incite_impossible;

    fc_snprintf(buf2, ARRAY_SIZE(buf2),
                _("You can't incite a revolt in %s."), city_name(pcity));
    incite_impossible.setText(QString(buf2));
    incite_impossible.exec();
  } else if (cost <= client_player()->economic.gold) {
    QMessageBox ask;

    fc_snprintf(buf2, ARRAY_SIZE(buf2),
                PL_("Incite a revolt for %d gold?\n%s",
                    "Incite a revolt for %d gold?\n%s", cost), cost, buf);
    ask.setText(QString(buf2));
    ask.setStandardButtons(QMessageBox::Cancel | QMessageBox::Ok);
    ask.setDefaultButton(QMessageBox::Cancel);
    ask.setIcon(QMessageBox::Question);
    ask.setWindowTitle(_("Incite a Revolt!"));
    ret = ask.exec();
    switch (ret) {
    case QMessageBox::Cancel:
      return;
      break;
    case QMessageBox::Ok:
      gui()->get_current_unit(&diplomat_id, &diplomat_target_id, ATK_CITY);
      request_diplomat_action(DIPLOMAT_INCITE, diplomat_id,
                              diplomat_target_id, 0);
      break;
    }
  } else {
    QMessageBox too_much;

    fc_snprintf(buf2, ARRAY_SIZE(buf2),
                PL_("Inciting a revolt costs %d gold.\n%s",
                    "Inciting a revolt costs %d gold.\n%s", cost), cost,
                buf);
    too_much.setText(QString(buf2));
    too_much.exec();
  }QMessageBox ask;
  int ret;
  QString str;
  char buf[1024];
  char buf2[1024];
  int diplomat_id;
  int diplomat_target_id;

  gui()->get_current_unit(&diplomat_id, &diplomat_target_id, ATK_UNIT);
  fc_snprintf(buf, ARRAY_SIZE(buf), PL_("Treasury contains %d gold.",
                                        "Treasury contains %d gold.",
                                        client_player()->economic.gold),
              client_player()->economic.gold);

  ask.setWindowTitle(QString(_("Bribe Enemy Unit")));
  if (cost <= client_player()->economic.gold) {
    fc_snprintf(buf2, ARRAY_SIZE(buf2), PL_("Bribe unit for %d gold?\n%s",
                                            "Bribe unit for %d gold?\n%s",
                                            cost), cost, buf);
    ask.setText(QString(buf2));
    ask.setStandardButtons(QMessageBox::Cancel | QMessageBox::Ok);
    ask.setDefaultButton(QMessageBox::Cancel);
    ask.setIcon(QMessageBox::Question);
    ret = ask.exec();
    switch (ret) {
    case QMessageBox::Cancel:
      break;
    case QMessageBox::Ok:
      request_diplomat_action(DIPLOMAT_BRIBE, diplomat_id,
                              diplomat_target_id, 0);
      break;
    default:
      break;
    }
  } else {
    fc_snprintf(buf2, ARRAY_SIZE(buf2),
                PL_("Bribing the unit costs %d gold.\n%s",
                    "Bribing the unit costs %d gold.\n%s", cost), cost, buf);
    ask.setWindowTitle(_("Traitors Demand Too Much!"));
    ask.exec();
  }*
  Action pillage for choice**********/
static void pillage_something(QVariant data1, QVariant data2)
{
  int punit_id;
  int what;
  struct unit *punit;
  struct extra_type *target;

  what = data1.toInt();
  punit_id = data2.toInt();
  punit = game_unit_by_number(punit_id);
  if (punit) {
    target = extra_by_number(what);
    request_new_unit_activity_targeted(punit, ACTIVITY_PILLAGE, target);
  }
  ::is_showing_pillage_dialog = false;*
  Action sabotage with spy for choice**********/
static void spy_sabotage(QVariant data1, QVariant data2)
{
  int diplomat_id;
  int diplomat_target_id;

  gui()->get_current_unit(&diplomat_id, &diplomat_target_id, ATK_CITY);
  if (NULL != game_unit_by_number(diplomat_id)
        && NULL != game_city_by_number(diplomat_target_id)) {
      request_diplomat_action(DIPLOMAT_SABOTAGE_TARGET, diplomat_id,
                              diplomat_target_id,  data2.toInt()+1);
    }
  QString str;
  QVariant qv1, qv2;
  int diplomat_id;
  int diplomat_target_id;
  pfcn_void func;
  choice_dialog *cd = new choice_dialog(_("_Sabotage"),
                                        _("Select Improvement to Sabotage"),
                                        gui()->game_tab_widget);
  int nr = 0;
  struct astring stra = ASTRING_INIT;

  gui()->get_current_unit(&diplomat_id, &diplomat_target_id, ATK_CITY);
  qv1 = diplomat_id;
  func = spy_sabotage;
  cd->add_item(QString(_("City Production")), func, qv1, -1, FALSE);
  city_built_iterate(pcity, pimprove) {
    if (pimprove->sabotage > 0) {
      func = spy_sabotage;
      str = city_improvement_name_translation(pcity, pimprove);
      qv2 = nr;
      cd->add_item(str, func, qv1, improvement_number(pimprove), FALSE);
      nr++;
    }
  } city_built_iterate_end;
  astr_set(&stra, _("At %s's Discretion"),
           unit_name_translation(game_unit_by_number(diplomat_id)));
  func = spy_sabotage;
  str = astr_str(&stra);
  cd->add_item(str, func, qv1, B_LAST, FALSE);
  cd->set_layout();
  cd->show_me();
  astr_free(&stra);extras extras)
{
  QString str;
  QVariant qv1, qv2;
  pfcn_void func;
  choice_dialog *cd;
  struct extra_type *tgt;

  if (is_showing_pillage_dialog){
    return;
  }
  cd = new choice_dialog(_("What To Pillage"), _("Select what to pillage:"),
                         gui()->game_tab_widget);
  qv2 = punit->id;
  while ((tgt = get_preferred_pillage(extras))) {
    int what;
    bv_extras what_extras;

    BV_CLR_ALL(what_extras);

    what = extra_index(tgt);
    BV_CLR(extras, what);
    BV_SET(what_extras, what);

    func = pillage_something;
    str = get_infrastructure_text(what_extras);
    qv1 = what;
    cd->add_item(str, func, qv1, qv2, FALSE);
  }
  cd->set_layout();
  cd->show_me();**
  Pops up a dialog to confirm disband of the unit(s)**/
void popup_disband_dialog(struct unit_list *punits)
{
  QMessageBox ask;
  int ret;
  QString str;

  if (!punits || unit_list_size(punits) == 0) {
    return;
  }
  if (unit_list_size(punits) == 1) {
    ask.setText(_("Are you sure you want to disband that unit?"));
  } else {
    str =
        QString(_("Are you sure you want to disband those %1 units?")).arg
        (unit_list_size(punits));
    ask.setText(str);
  }
  ask.setWindowTitle(_("Disband"));
  ask.setStandardButtons(QMessageBox::Cancel | QMessageBox::Ok);
  ask.setDefaultButton(QMessageBox::Cancel);
  ask.setIcon(QMessageBox::Question);
  ask.setWindowTitle(_("Disband unit(s)"));
  ret = ask.exec();

  switch (ret) {
  case QMessageBox::Cancel:
    return;
    break;
  case QMessageBox::Ok:
    unit_list_iterate(punits, punit) {
      if (!unit_has_type_flag(punit, UTYF_UNDISBANDABLE)) {
        request_unit_disband(punit);
      }
    } unit_list_iterate_end;
    break;
  }qDebug() << Q_FUNC_INFO << "PORTME";
  Ruleset (modpack) has suggested loading certain sound/
void popup_soundset_suggestion_dialog(void)
{
  qDebug() << Q_FUNC_INFO << "PORTME";false;int i;
  QList <choice_dialog *> cd_list;

  cd_list = gui()->game_tab_widget->findChildren <choice_dialog *>();
  for (i = 0; i < cd_list.count(); i++) {
      cd_list[i]->close();
  }choice_dialog *cd = gui()->get_diplo_dialog();

  if (cd != NULL){
    return cd->unit_id;
  } else {
    return -1;
  }
  Closes the/
void close_diplomat_dialog(void)
{
  choice_dialog *cd;

  cd = gui()->get_diplo_dialog();
  if (cd != NULL){
    cd->close();
  }
  gui()->set_current_unit(-1, -1, ATK_UNIT);
  gui()->set_current_unit(-1, -1, ATK_CITY);char buf2[1024];
  struct city *destcity;
  struct unit *caravan;
  QString wonder;
  QString str;
  QVariant qv1, qv2;
  pfcn_void func;
  int i;
  QVBoxLayout *layout;
  QPushButton *qpb;

  if (caravan_dialog == NULL) {
    return;
  }
  destcity = game_city_by_number(caravan_city_id);
  caravan = game_unit_by_number(caravan_unit_id);
  i = 0;
  layout = caravan_dialog->get_layout();
  foreach (func, caravan_dialog->func_list) {
    if (func == caravan_help_build) {
      if (destcity && caravan
          && unit_can_help_build_wonder(caravan, destcity)) {
        fc_snprintf(buf2, sizeof(buf2),
                  _("Help build _Wonder (%d remaining)"),
                  impr_build_shield_cost(destcity->production.value.building)
                  - destcity->shield_stock);
        wonder = QString(buf2);
      } else {
        wonder = QString(_("Help build _Wonder"));
      }
      qpb = qobject_cast<QPushButton *>(layout->itemAt(i + 1)->widget());
      qpb->setText(wonder);
    }
    i++;
  }
  Player has gained a new tech/
void show_tech_gained_dialog(Tech_type_id tech)
{
  Show tileset error dialog/
void show_tileset_error(const char *msg
  Popup dialog for upgrade units/
void popup_upgrade_dialog(struct unit_list *punits)
{
  char buf[512];
  QMessageBox ask;
  int ret;

  if (!punits || unit_list_size(punits) == 0) {
    return;
  }
  if (!get_units_upgrade_info(buf, sizeof(buf), punits)) {
    ask.setText(QString(buf));
    ask.setWindowTitle(_("Upgrade Unit!"));
  } else {
    ask.setWindowTitle(_("Upgrade Obsolete Units"));
    ask.setStandardButtons(QMessageBox::Cancel | QMessageBox::Ok);
    ask.setDefaultButton(QMessageBox::Cancel);
    ask.setIcon(QMessageBox::Question);
    ret = ask.exec();

    switch (ret) {
    case QMessageBox::Cancel:
      return;
      break;
    case QMessageBox::Ok:
      unit_list_iterate(punits, punit) {
        request_unit_upgrade(punit);
      } unit_list_iterate_end;
      break;
    }
  }
  Contructor for unit_select/
unit_select::unit_select(tile *ptile, QWidget *parent)
{
  QPoint p, final_p;

  setParent(parent);
  utile = ptile;
  pix = NULL;
  show_line = 0;
  highligh_num = -1;
  ufont = new QFont;
  ufont->setItalic(true);
  info_font = gui()->fc_fonts.get_font("gui_qt_font_notify_label");
  update_units();
  h_pix = NULL;
  create_pixmap();
  p = mapFromGlobal(QCursor::pos());
  setMouseTracking(true);
  final_p.setX(p.x());
  final_p.setY(p.y());
  if (p.x() + width() > parentWidget()->width()) {
    final_p.setX(parentWidget()->width() - width());
  }
  if (p.y() - height() < 0) {
    final_p.setY(height());
  }
  move(final_p.x(), final_p.y() - height());
}

  Destructor for unit select/
unit_select::~unit_select()
{
    delete h_pix;
    delete pix;
    delete ufont;
  Create pixmap of whole widget except borders (pix)/
void unit_select::create_pixmap()
{
  struct unit *punit;
  QPixmap *tmp_pix;
  struct canvas *unit_pixmap;
  QList <QPixmap*>pix_list;
  QPainter p;
  QString str;
  int x, y, i;
  int rate, f;
  int a;
  QPen pen;
  QFontMetrics fm(*info_font);

  if (pix != NULL) {
    delete pix;
    pix = NULL;
  };

  if (unit_list.count() > 0) {
  punit = unit_list.at(0);
  item_size.setWidth(tileset_full_tile_width(tileset));
  item_size.setHeight(tileset_tile_height(tileset) * 3 / 2);
  more = false;
  if (h_pix == NULL) {
    h_pix = new QPixmap(item_size.width(), item_size.height());
    h_pix->fill(QColor(100, 100, 100, 140));
  }
  if (unit_list.size() < 5) {
    row_count = 1;
    pix = new QPixmap((unit_list.size()) * item_size.width(),
                      item_size.height());
  } else if (unit_list.size() < 9) {
    row_count = 2;
    pix = new QPixmap(4 * item_size.width(), 2 * item_size.height());
  } else {
    row_count = 3;
    if (unit_list_size(utile->units) > unit_list.size() - 1) {
      more = true;
    }
    pix = new QPixmap(4 * item_size.width(), 3 * item_size.height());
  }
  pix->fill(Qt::transparent);
  foreach(punit, unit_list) {
    unit_pixmap = qtg_canvas_create(tileset_full_tile_width(tileset),
                                    tileset_tile_height(tileset) * 3 / 2);
    unit_pixmap->map_pixmap.fill(Qt::transparent);
    put_unit(punit, unit_pixmap, 1.0, 0, 0);
    pix_list.push_back(&unit_pixmap->map_pixmap);
  }
  a = qMin(item_size.width() / 4, 12);
  x = 0, y = -item_size.height(), i = -1;
  p.begin(pix);
  ufont->setPixelSize(a);
  p.setFont(*ufont);
  pen.setColor(QColor(232, 255, 0));
  p.setPen(pen);

  while (!pix_list.isEmpty()) {
    tmp_pix = pix_list.takeFirst();
    i++;
    if (i % 4 == 0) {
      x = 0;
      y = y + item_size.height();
    }
    punit = unit_list.at(i);
    Q_ASSERT(punit != NULL);
    rate = unit_type(punit)->move_rate;
    f = ((punit->fuel) - 1);
    if (i == highligh_num) {
      p.drawPixmap(x, y, *h_pix);
      p.drawPixmap(x, y, *tmp_pix);
    } else {
      p.drawPixmap(x, y, *tmp_pix);
    }

    if (utype_fuel(unit_type(punit))) {
      str = QString(move_points_text
                   ((rate * f) + punit->moves_left, NULL, NULL, false));
    } else {
      str = QString(move_points_text(punit->moves_left, NULL, NULL, false));
    }
    /* TRANS: MP = Movement points */
    str = QString(_("MP:")) + str;
    p.drawText(x, y + item_size.height() - 4, str);

    x = x + item_size.width();
    delete tmp_pix;
  }
  p.end();
  setFixedWidth(pix->width() + 20);
  setFixedHeight(pix->height() + 2 * (fm.height() + 6));
  qDeleteAll(pix_list.begin(), pix_list.end());
  }
  Event for mouse moving around unit_select/
void unit_select::mouseMoveEvent(QMouseEvent *event)
{
  int a, b;
  int old_h;
  QFontMetrics fm(*info_font);

  old_h = highligh_num;
  highligh_num = -1;
  if (event->x() > width() - 11
      || event->y() > height() - fm.height() - 5
      || event->y() < fm.height() + 3 || event->x() < 11) {
    /** do nothing if mouse is on border, just skip next if */
  } else if (row_count > 0) {
    a = (event->x() - 10) / item_size.width();
    b = (event->y() - fm.height() - 3) / item_size.height();
    highligh_num = b * 4 + a;
  }
  if (old_h != highligh_num) {
    create_pixmap();
    update();
  }
  Mouse pressed event for unit_select.
  Left Button - chooses units
  Right Button - closes widget/
void unit_select::mousePressEvent(QMouseEvent *event)
{
  struct unit *punit;
  if (event->button() == Qt::RightButton) {
    was_destroyed = true;
    close();
    destroy();
  }
  if (event->button() == Qt::LeftButton && highligh_num != -1
      && highligh_num < unit_list.count()) {
    punit = unit_list.at(highligh_num);
    unit_focus_set(punit);
    was_destroyed = true;
    close();
    destroy();
  }
  Redirected paint event/
void unit_select::paint(QPainter *painter, QPaintEvent *event)
{
  QFontMetrics fm(*info_font);
  int h, i;
  int *f_size;
  QPen pen;
  QString str, str2;
  struct unit *punit;
  int point_size = info_font->pointSize();
  int pixel_size = info_font->pixelSize();

  if (point_size < 0) {
    f_size = &pixel_size;
  } else {
    f_size = &point_size;
  }
  if (highligh_num != -1 && highligh_num < unit_list.count()) {
    punit = unit_list.at(highligh_num);
    str2 = QString(unit_activity_text(punit))
          + QString(" ") + QString(_("HP")) + QString(": ")
          + QString::number(punit->hp) + QString("/")
          + QString::number(unit_type(punit)->hp);
  }
  str = QString::number(unit_list_size(utile->units)) + " "
        + QString(_("units"));
  for (i = *f_size; i > 4; i--) {
    if (point_size < 0) {
      info_font->setPixelSize(i);
    } else  {
      info_font->setPointSize(i);
    }
    QFontMetrics qfm(*info_font);
    if (10 + qfm.width(str2) < width()) {
      break;
    }
  }
  h = fm.height();
  painter->setBrush(QColor(0, 0, 0, 135));
  painter->drawRect(0, 0, width(), height());
  if (pix != NULL) {
    painter->drawPixmap(10, h + 3, *pix);
    pen.setColor(QColor(232, 255, 0));
    painter->setPen(pen);
    painter->setFont(*info_font);
    painter->drawText(10, h, str);
    if (highligh_num != -1 && highligh_num < unit_list.count()) {
      painter->drawText(10, height() - 5, str2);
    }
  }
  if (point_size < 0) {
    info_font->setPixelSize(*f_size);
  } else {
    info_font->setPointSize(*f_size);
  }
}

  Paint event, redirects to paint(...)/
void unit_select::paintEvent(QPaintEvent *event)
{
  QPainter painter;

  painter.begin(this);
  paint(&painter, event);
  painter.end();
  Function from abstract fcwidget to update menu, its not needed
  cause widget is easy closable via right mouse click/
void unit_select::update_menu()
{
  Updates unit list on tile/
void unit_select::update_units()
{
  int i = 1;

  if (utile == NULL) {
    struct unit *punit = head_of_units_in_focus();
    if (punit) {
      utile = unit_tile(punit);
    }
  }
  unit_list.clear();
  unit_list_iterate(utile->units, punit) {
    if (i > show_line * 4)
      unit_list.push_back(punit);
    i++;
  } unit_list_iterate_end;
  Mouse wheel event for unit_select/
void unit_select::wheelEvent(QWheelEvent *event)
{
  int nr;

  if (more == false && utile == NULL) {
    return;
  }
  nr = qCeil(static_cast<qreal>(unit_list_size(utile->units)) / 4) - 3;
  if (event->delta() < 0) {
    show_line++;
    show_line = qMin(show_line, nr);
  } else {
    show_line--;
    show_line = qMax(0, show_line);
  }
  update_units();
  create_pixmap();
  update();
  event->accept();*
 Set current unit handled in diplo**********/
void fc_client::set_current_unit(int curr, int target,
                                 action_target_kind tgt)
{
  current_unit_id = curr;
  current_unit_target_id[tgt] = target;*
 Get current unit handled in diplo**********/
void fc_client::get_current_unit(int *curr, int *target,
                                 action_target_kind tgt)
{
  *curr = current_unit_id;
  *target = current_unit_target_id[tgt];*
 Set current diplo**********/
void fc_client::set_diplo_dialog(choice_dialog *widget)
{
  opened_dialog = widget;*
 Get current diplo**********/
choice_dialog* fc_client::get_diplo_dialog()
{
  return opened_dialog;
}

ENDREP
DELTA 23072 123835 4525
SVN  ¸¸2
$ † ¤ ±u†Application>
#include <QInputDialog>ENDREP
DELTA 23072 128390 644
SVN  ‘	‘(
 …o š ‹…jQt
#include <QTableWidget>ENDREP
DELTA 21589 0 5036
SVN  §Ñ8=­< † ž )†€3 G » G‰@€\ VŽ@« G‰@€N G  %ˆt yŠ€V „Œ !€h G  #’C€ v”l€m UŽ@£ G‰@€„S VŽ@Ÿ G‰@€‚ QŽ@™ G‰@€†K UŽ@¦ G‰@€ƒz G  C–/¾ \˜%Š C˜ G‰@‡ d’~— ž€% ~ŸY€ƒO ¡€„\ Q¤;€‡7// Qt
#include <QItemDelegate>Variant;
class QVBoxLayout;

#define NUM_INFO_FIELDS 12

// client
#include "canvas.h"

// Qt
#include <QProgressBar>
#include <QTableWidget>

class city_dialog;
class QChecBox;

******
  Subclassed QProgressBar to receive clicked signal
*****/
class progress_bar: public QProgressBar
{
  Q_OBJECT
signals:
  void clicked();
public:
  progress_bar(QWidget *parent): QProgressBar(parent) {}
  void mousePressEvent(QMouseEvent *event) {
    emit clicked();
  }ubclassed QLabel to receive clicked signal
*****/
class fc_label: public QLabel
{
  Q_OBJECT
signals:
  void clicked();
public:
  fc_label(QWidget *parent): QLabel(parent) {}
  void mousePressEvent(QMouseEvent *event) {
    emit clicked();
  }
};


   void mouseMoveEvent(QMouseEvent *event);
  void mousePressEvent(QMouseEvent *event);   QHBoxLayout *layout;
  QList<unit_item *> unit_list;
  void mouseMoveEvent(QMouseEvent *event);

};


 public QWidget
{

  Q_OBJECT
  canvas *view;
  canvas *miniview;

public:

  city_map(QWidget *parent);
  ~city_map();
  void set_pixmap(struct city *pcity)  int radius;
  int wdth;
  int hight;
  int cutted_width;
  int cutted_height;
  int delta_x;
  int delta_y;Item delegate for production popup
*****/
class city_production_delegate: public QItemDelegate
{
  Q_OBJECT

public:
  city_production_delegate(QPoint sh, QObject *parent, struct city* city);
  ~city_production_delegate() {}
  void paint(QPainter *painter, const QStyleOptionViewItem &option,
             const QModelIndex &index) const;
  QSize sizeHint(const QStyleOptionViewItem &option,
                 const QModelIndex &index) const;
private:
  int item_height;
  QPoint pd;
  struct city *pcity;
protected:
  void drawFocus(QPainter *painter, const QStyleOptionViewItem &option,
                 const QRect &rect) const;ingle item in production popup
*****/
class production_item: public QObject
{
  Q_OBJECT

public:
  production_item(struct universal *ptarget);
  ~production_item();
  inline int columnCount() const {
    return 1;
  }
  QVariant data() const;
  bool setData();
private:
  struct universal *target;
  City production model
****/
class city_production_model : public QAbstractListModel
{
  Q_OBJECT
public:
  city_production_model(struct city *pcity, bool f, bool su,
                        QObject *parent = 0);
  ~city_production_model();
  inline int rowCount(const QModelIndex &index = QModelIndex()) const {
    Q_UNUSED(index);
    return (qCeil(static_cast<float>(city_target_list.size()) / 3));
  }
  int columnCount(const QModelIndex &parent = QModelIndex()) const {
    Q_UNUSED(parent);
    return 3;
  }
  QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
  bool setData(const QModelIndex &index, const QVariant &value,
               int role = Qt::DisplayRole);
  QPoint size_hint();
  void populate();
  QPoint sh;
private:
  QList<production_item *> city_target_list;
  struct city *mcity;
  bool future_t;
  bool show_units;Class for popup avaialable production
*****/
class production_widget: public QTableView
{
  Q_OBJECT
  city_production_model *list_model;
  city_production_delegate *c_p_d;
public:
  production_widget(struct city *pcity, bool future, int when, int curr,
                    bool show_units);
  ~production_widget();
public slots:
  void prod_selected(const QItemSelection &sl, const QItemSelection &ds);
private:
  void mousePressEvent(QMouseEvent *event);
  struct city *pw_city;
  int when_change;
  int curr_selection;
  bool sh_units;
};


 public QLabel
{

  Q_OBJECT

public:

  city_label(int type,   int type***
  Cdialog: public QDialog
QGridLayout *happiness_grid_layout;
  QGridLayout *cma_grid_layout;
  city_map *view;
  city_map *info_view;
  city_label *citizens_label;
  city_label *lab_table[6]Label *cma_info_text;
  QLabel *cma_result;
  QLabel *supp_units;
  QLabel *curr_units;
  progress_bar *production_combo;
  QTableWidget *production_table;
  progress_bar *production_combo_p;
  QTableWidget *p_table_p;
  QTableWidget *nationality_table;
  QTableWidget *cma_table;
  QPushButton *buy_button_p;
  QCheckBox *cma_celeb_checkbox;
  QCheckBox *future_targets_p;
  QCheckBox *show_units_p;
  QCheckBox *disband_at_one;
  QRadioButton *r1, *r2, *r3, *r4PushButton *button;
  QPushButton *buy_button;
  QPushButton *item_button;
  QPushButton *item_button_p;
  QPushButton *cma_enable_but;
  QPushButton *next_city_but;
  QPushButton *prev_city_but;
  QPushButton *but_remove_item;
  QPushButton *but_clear_worklist;
  QPixmap *citizen_pixmap;
  unit_info *current_units;
  unit_info *supported_units;
  fc_label *lcity_name;
  fc_label *pcity_name;
  int selected_row_p;
  QSlider* slider_tab[2*O_LAST+2];

public:

  city_dialog(QWidget *parent = 0);
  ~city_dialog();
  void setup_ui(struct city *qcity);
  void refresh();
  struct city *pcity;

private:
  void update_settings();
  void update_nation_table();
  void update_cma_tab();
  void update_disabled();

private slots:

  void next_city();
  void prev_city();
  void production_changed(int index);
  void show_targets();
  void show_targets_worklist();
  void buy();
  void dbl_click(QTableWidgetItem *item);
  void dbl_click_p(QTableWidgetItem *item);
  void delete_prod();;
  void item_selected(const QItemSelection &sl, const QItemSelection &ds);
  void clear_worklist();
  void save_worklist();
  void display_worklist_menu(const QPoint &p);
  void disband_state_changed(int state);
  void update_results_text();
  void cma_slider(int val);
  void cma_celebrate_changed(int val);
  void cma_remove();
  void cma_enable();
  void cma_changed();
  void cma_selected(const QItemSelection &sl, const QItemSelection &ds);
  void save_cma();
  void city_rename();
};

void destroy_city_dialog();

#endif                          /* FC__CITYDLG_H */
ENDREP
DELTA 23624 3484 551
SVN  ƒŒcƒ0H …o €H ƒ†y…jQt
#include <QApplication>
#include <QMainWindow>
#include <QMessageBox>ENDREP
DELTA 23053 152578 19950
SVN  ²%³"| …p €F é?…k¶ Âwï.Qt
#include <QApplication>
#include <QHeaderView>
#include <QSplitter>ype_translated_name(
                                 ENDREP
DELTA 23347 7919 169
SVN  ˆPŠ{ …k € ‚c…f€w ÿB‰Qt
#include <QApplication>
#include <QMainWindow>
#include <QLineEdit>
#include <QStatusBar>
#include <QTabBar>
#include <QTextEdit>#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
  QTextCodec::setCodecForCStrings(QTextCodec::codecForName("UTF-8"));
#endifENDREP
DELTA 22934 958 1872
SVN  Ù_Ùz&W †S Š ƒd†F… 4Š/ —` ¡~™¸ —D»5 †gÒxMessageBoxfalseQIcon app_icon;
 = new call_me_back; /* removed in mr_idler:idling() */
ENDREP
DELTA 23100 0 37567
SVN  ƒªƒª% …o – ‚êf…jƒ ¹7‚ðNQt
#include <QToolTip>1.0ENDREP
id: 6je.5ck.r23687/61605
type: file
pred: 6je.5ck.r23072/129063
count: 5
text: 23687 54610 47 2216 c2f7804de6597021c875effcd31ad706
cpath: /trunk/client/gui-qt/messagewin.cpp
copyroot: 15280 /trunk

id: gr2.5ck.r23687/61804
type: file
pred: gr2.5ck.r23053/175934
count: 2
text: 23687 54687 6022 10424 38ef952183891a111906b899b647924a
cpath: /trunk/client/gui-qt/citydlg.h
copyroot: 15280 /trunk

id: 6ja.5ck.r23687/62001
type: file
pred: 6ja.5ck.r23624/19500
count: 29
text: 23687 60735 97 50864 98fa7b921b0b56f45162f4552c163083
cpath: /trunk/client/gui-qt/menu.cpp
copyroot: 15280 /trunk

id: 6ir.5ck.r23687/62195
type: file
pred: 6ir.5ck.r23542/41669
count: 32
text: 23687 2592 51900 67531 42306875ba613d96007ac434511ad3d6
cpath: /trunk/client/gui-qt/dialogs.cpp
copyroot: 15280 /trunk

id: 6jg.5ck.r23687/62394
type: file
pred: 6jg.5ck.r23072/129855
count: 5
text: 23687 1448 161 25687 65f4753f3582a434d863b7c7139d8cde
cpath: /trunk/client/gui-qt/optiondlg.cpp
copyroot: 15280 /trunk

id: 6ik.5ck.r23687/62593
type: file
pred: 6ik.5ck.r23312/345897
count: 10
text: 23687 154 1136 91998 b55c81939668605582eff41ec6742d95
cpath: /trunk/client/gui-qt/citydlg.cpp
copyroot: 15280 /trunk

id: 6j6.5ck.r23687/62791
type: file
pred: 6j6.5ck.r23072/130456
count: 9
text: 23687 54522 57 7218 1a0aee191281122d6b472b2ab190bbfc
cpath: /trunk/client/gui-qt/mapctrl.cpp
copyroot: 15280 /trunk

id: 6js.5ck.r23687/62987
type: file
pred: 6js.5ck.r23072/130655
count: 10
text: 23687 2194 367 42096 7ac0ce6cc5c2ef283e67305bde90362b
cpath: /trunk/client/gui-qt/repodlgs.cpp
copyroot: 15280 /trunk

id: 6jk.5ck.r23687/63186
type: file
pred: 6jk.5ck.r23284/37584
count: 6
text: 23687 60860 154 22946 d5df9a4f05aa2dc36660db1e5fdb8a26
cpath: /trunk/client/gui-qt/plrdlg.cpp
copyroot: 15280 /trunk

id: 6lc.5ck.r23687/63382
type: file
pred: 6lc.5ck.r23347/47629
count: 29
text: 23687 61046 284 17675 5065aceb0a3e006c889bdad937ce5c45
cpath: /trunk/client/gui-qt/fc_client.cpp
copyroot: 15280 /trunk

id: 6ji.5ck.r23687/63582
type: file
pred: 6ji.5ck.r23541/1173
count: 15
text: 23687 1641 527 45958 ad09d8abd24c07f68d01b18a27350010
cpath: /trunk/client/gui-qt/pages.cpp
copyroot: 15280 /trunk

id: 6il.5ck.r23687/63776
type: file
pred: 6il.5ck.r23072/131255
count: 5
text: 23687 1320 97 29127 2f41d259309f8621ef8acbc99d243b1c
cpath: /trunk/client/gui-qt/cityrep.cpp
copyroot: 15280 /trunk

id: 6ld.5ck.r23687/63972
type: file
pred: 6ld.5ck.r23347/47825
count: 23
text: 23687 0 125 6689 60c91d81135d9d576dbb3c56cedd4fa2
cpath: /trunk/client/gui-qt/fc_client.h
copyroot: 15280 /trunk

id: 6j8.5ck.r23687/64165
type: file
pred: 6j8.5ck.r23312/346491
count: 18
text: 23687 61522 56 54565 f508d474bf9838d5f5a1e2876ed5d62e
cpath: /trunk/client/gui-qt/mapview.cpp
copyroot: 15280 /trunk

id: 6j1.5ck.r23687/64363
type: file
pred: 6j1.5ck.r23072/131653
count: 14
text: 23687 61358 136 11514 9b9b3cda59f7b01dd095cf6c78a40370
cpath: /trunk/client/gui-qt/gui_main.cpp
copyroot: 15280 /trunk

PLAIN
K 11
Makefile.am
V 24
file 6if.5ck.r23654/3933
K 10
canvas.cpp
V 26
file 6ig.5ck.r23312/346096
K 8
canvas.h
V 25
file 6ih.5ck.r22768/29447
K 12
chatline.cpp
V 25
file 6ii.5ck.r21547/75234
K 10
chatline.h
V 25
file 6ij.5ck.r18893/72448
K 11
citydlg.cpp
V 25
file 6ik.5ck.r23687/62593
K 9
citydlg.h
V 25
file gr2.5ck.r23687/61804
K 11
cityrep.cpp
V 25
file 6il.5ck.r23687/63776
K 9
cityrep.h
V 25
file 6im.5ck.r23004/46042
K 10
colors.cpp
V 26
file 6in.5ck.r19259/510209
K 8
colors.h
V 24
file 6io.5ck.r19190/3276
K 14
connectdlg.cpp
V 25
file 6ip.5ck.r22313/30662
K 12
connectdlg.h
V 25
file 6iq.5ck.r18893/76659
K 11
dialogs.cpp
V 25
file 6ir.5ck.r23687/62195
K 9
dialogs.h
V 24
file 6is.5ck.r23452/1329
K 12
diplodlg.cpp
V 26
file 6it.5ck.r19259/509220
K 10
diplodlg.h
V 25
file 6iu.5ck.r18893/68245
K 13
fc_client.cpp
V 25
file 6lc.5ck.r23687/63382
K 11
fc_client.h
V 25
file 6ld.5ck.r23687/63972
K 11
finddlg.cpp
V 26
file 6iv.5ck.r19259/511192
K 9
finddlg.h
V 25
file 6iw.5ck.r18893/70592
K 11
gotodlg.cpp
V 26
file 6ix.5ck.r19259/509418
K 9
gotodlg.h
V 25
file 6iy.5ck.r18893/68578
K 12
graphics.cpp
V 26
file 6iz.5ck.r23072/130258
K 10
graphics.h
V 25
file 6j0.5ck.r18893/68912
K 12
gui_main.cpp
V 25
file 6j1.5ck.r23687/64363
K 10
gui_main.h
V 24
file oxo.5ck.r22934/3048
K 11
helpdlg.cpp
V 26
file 6j2.5ck.r19259/511783
K 9
helpdlg.h
V 25
file 6j3.5ck.r18893/72117
K 12
inteldlg.cpp
V 26
file 6j4.5ck.r19259/510601
K 10
inteldlg.h
V 25
file 6j5.5ck.r18893/69584
K 14
luaconsole.cpp
V 26
file 76c.5ck.r23072/129264
K 12
luaconsole.h
V 24
file 76d.5ck.r20309/2264
K 11
mapctrl.cpp
V 25
file 6j6.5ck.r23687/62791
K 9
mapctrl.h
V 25
file 6j7.5ck.r18893/69418
K 11
mapview.cpp
V 25
file 6j8.5ck.r23687/64165
K 9
mapview.h
V 24
file 6j9.5ck.r23059/2475
K 8
menu.cpp
V 25
file 6ja.5ck.r23687/62001
K 6
menu.h
V 25
file 6jb.5ck.r23004/45456
K 14
messagedlg.cpp
V 26
file 6jc.5ck.r19259/508025
K 12
messagedlg.h
V 25
file 6jd.5ck.r18893/75986
K 14
messagewin.cpp
V 25
file 6je.5ck.r23687/61605
K 12
messagewin.h
V 25
file 6jf.5ck.r18893/74646
K 13
optiondlg.cpp
V 25
file 6jg.5ck.r23687/62394
K 11
optiondlg.h
V 25
file 6jh.5ck.r22593/46398
K 9
pages.cpp
V 25
file 6ji.5ck.r23687/63582
K 7
pages.h
V 25
file 6jj.5ck.r21547/73863
K 10
plrdlg.cpp
V 25
file 6jk.5ck.r23687/63186
K 8
plrdlg.h
V 26
file 6jl.5ck.r23053/177527
K 15
qtg_cxxside.cpp
V 26
file 6jo.5ck.r23312/345696
K 13
qtg_cxxside.h
V 26
file 6jp.5ck.r23312/346291
K 12
ratesdlg.cpp
V 25
file 6jq.5ck.r21586/32162
K 10
ratesdlg.h
V 25
file 6jr.5ck.r21547/72493
K 12
repodlgs.cpp
V 25
file 6js.5ck.r23687/62987
K 10
repodlgs.h
V 25
file 6jt.5ck.r23004/45260
K 16
spaceshipdlg.cpp
V 26
file 6ju.5ck.r19259/507628
K 14
spaceshipdlg.h
V 25
file 6jv.5ck.r18893/75317
K 10
sprite.cpp
V 25
file 6jw.5ck.r21547/74252
K 8
sprite.h
V 24
file 6jx.5ck.r19190/3658
K 10
themes.cpp
V 23
file 6jy.5ck.r20366/177
K 16
voteinfo_bar.cpp
V 26
file 6jz.5ck.r19259/508225
K 14
voteinfo_bar.h
V 25
file 6k0.5ck.r18893/76154
K 9
wldlg.cpp
V 26
file 6k1.5ck.r19259/507830
K 7
wldlg.h
V 25
file 6k2.5ck.r18893/75484
END
ENDREP
id: 6ie.5ck.r23687/67630
type: dir
pred: 6ie.5ck.r23654/7202
count: 96
text: 23687 64563 3054 3054 85e0e62c31799e36ea0ec9e5b86822ed
props: 19234 0 72 0 33e6d17e258682e48f787b5a39cf23f3
cpath: /trunk/client/gui-qt
copyroot: 15280 /trunk

PLAIN
K 11
Makefile.am
V 24
file 5f.5ck.r23142/12550
K 6
agents
V 23
dir zf.5ck.r22382/38489
K 11
attribute.c
V 24
file xh.5ck.r22340/22167
K 11
attribute.h
V 24
file xi.5ck.r18863/23649
K 7
audio.c
V 24
file 139.5ck.r22180/7668
K 7
audio.h
V 24
file 13a.5ck.r22180/7911
K 12
audio_none.c
V 26
file 13d.5ck.r19259/462511
K 12
audio_none.h
V 25
file 13e.5ck.r18863/20841
K 11
audio_sdl.c
V 25
file 13f.5ck.r19354/73618
K 11
audio_sdl.h
V 25
file 13g.5ck.r18863/23885
K 17
chatline_common.c
V 26
file 14q.5ck.r19259/494007
K 17
chatline_common.h
V 25
file 14r.5ck.r18863/23155
K 16
citydlg_common.c
V 25
file z4.5ck.r23312/315678
K 16
citydlg_common.h
V 24
file z5.5ck.r18863/18619
K 13
cityrepdata.c
V 22
file mb.5ck.r23375/139
K 13
cityrepdata.h
V 24
file mc.5ck.r18863/19121
K 13
client_main.c
V 24
file 2f.5cp.r23325/14823
K 13
client_main.h
V 24
file hz.5cq.r18863/25358
K 8
climap.c
V 24
file 197.5ck.r20232/3008
K 8
climap.h
V 25
file 198.5ck.r18863/24126
K 9
climisc.c
V 24
file d5.5ck.r23027/92426
K 9
climisc.h
V 24
file i0.5ck.r23027/96165
K 8
clinet.c
V 23
file hc.5ck.r22513/7891
K 8
clinet.h
V 24
file i1.5ck.r18863/24866
K 15
colors_common.c
V 24
file 33a.5ck.r22855/3020
K 15
colors_common.h
V 25
file 33b.5ck.r19135/48891
K 19
connectdlg_common.c
V 24
file 2fw.5ck.r23431/2350
K 19
connectdlg_common.h
V 25
file 2fx.5ck.r19154/53802
K 9
control.c
V 23
file gz.5ck.r23600/1965
K 9
control.h
V 23
file i2.5ck.r23600/6834
K 7
dummy.c
V 23
file 4f9.5ck.r15641/551
K 12
dummycxx.cpp
V 23
file 6kr.5ck.r18947/939
K 8
editor.c
V 26
file 3bg.5ck.r23312/350003
K 8
editor.h
V 23
file 3bh.5ck.r23105/702
K 11
ggzclient.c
V 26
file 394.5ck.r20126/104106
K 11
ggzclient.h
V 25
file 395.5ck.r18863/21083
K 17
global_worklist.c
V 26
file 4i6.5ck.r19259/493810
K 17
global_worklist.h
V 25
file 4i7.5ck.r18863/22960
K 6
goto.c
V 23
file vu.5ck.r23588/2214
K 6
goto.h
V 24
file vv.5ck.r23027/81018
K 11
gui-gtk-2.0
V 23
dir zs.5ck.r23642/16718
K 11
gui-gtk-3.0
V 22
dir zs.5g7.r23674/4931
K 6
gui-qt
V 24
dir 6ie.5ck.r23687/67630
K 7
gui-sdl
V 24
dir 16t.5ck.r23659/54246
K 8
gui-sdl2
V 24
dir 16t.5l8.r23659/48379
K 8
gui-stub
V 23
dir mh.5ck.r23542/41425
K 7
gui-xaw
V 23
dir 9o.5ck.r23542/25419
K 14
gui_cbsetter.c
V 26
file a3c.5ck.r23312/344798
K 14
gui_cbsetter.h
V 25
file a3d.5ck.r20753/37736
K 15
gui_interface.c
V 26
file 6jm.5ir.r23312/328430
K 15
gui_interface.h
V 26
file 6jn.5is.r23312/328650
K 10
helpdata.c
V 22
file h1.5ck.r23668/168
K 10
helpdata.h
V 24
file i3.5ck.r21778/46227
K 7
include
V 23
dir b8.5ck.r23542/27564
K 19
luaconsole_common.c
V 22
file 75z.5ck.r20372/58
K 19
luaconsole_common.h
V 25
file 760.5ck.r20306/31022
K 9
luascript
V 23
dir 761.5ck.r22514/7638
K 16
mapctrl_common.c
V 25
file 15m.5ck.r20865/59741
K 16
mapctrl_common.h
V 25
file 15n.5ck.r19893/12504
K 16
mapview_common.c
V 24
file z2.5ck.r23659/54490
K 16
mapview_common.h
V 25
file z3.5ck.r23312/345243
K 19
messagewin_common.c
V 25
file 14s.5ck.r19354/71979
K 19
messagewin_common.h
V 25
file 14t.5ck.r18863/21579
K 9
options.c
V 23
file dc.5ck.r23155/7759
K 9
options.h
V 23
file i4.5ck.r23155/1631
K 17
overview_common.c
V 25
file 2yk.5ck.r23659/48640
K 17
overview_common.h
V 24
file 2yl.5ck.r19511/5441
K 10
packhand.c
V 23
file n.5ck.r23642/16965
K 10
packhand.h
V 24
file i5.5ck.r18863/20596
K 15
plrdlg_common.c
V 23
file 14u.5ck.r23426/823
K 15
plrdlg_common.h
V 25
file 14v.5ck.r18863/21328
K 17
repodlgs_common.c
V 25
file 11i.5ck.r22325/76263
K 17
repodlgs_common.h
V 25
file 11j.5ck.r19589/11861
K 9
reqtree.c
V 25
file 2ym.5ck.r22451/33416
K 9
reqtree.h
V 24
file 2yn.5ck.r19057/3837
K 9
servers.c
V 25
file 33x.5ck.r22325/81040
K 9
servers.h
V 25
file 33y.5ck.r20478/36372
K 6
text.c
V 25
file 2g3.5ck.r23390/43659
K 6
text.h
V 25
file 2g4.5ck.r22264/31375
K 15
themes_common.c
V 25
file 352.5ck.r19354/73121
K 15
themes_common.h
V 25
file 353.5ck.r18863/22710
K 10
tilespec.c
V 24
file hl.5ck.r23662/58467
K 10
tilespec.h
V 24
file i6.5ck.r23642/22272
K 19
unitselect_common.c
V 24
file 76v.5ck.r20397/3580
K 19
unitselect_common.h
V 24
file 76w.5ck.r20397/3746
K 14
update_queue.c
V 25
file 4jw.5ck.r22413/14226
K 14
update_queue.h
V 25
file 4jx.5ck.r18863/22078
K 10
voteinfo.c
V 25
file 4fe.5ck.r19354/72931
K 10
voteinfo.h
V 25
file 4ff.5ck.r18863/22523
END
ENDREP
id: d.5ck.r23687/72148
type: dir
pred: d.5ck.r23674/9473
count: 5783
text: 23687 67867 4268 4268 d3f85c7ea91285f29f60863c8c9a6fd8
props: 20641 0 184 0 7e44dc5a5223e43acf7a5285ba8bedd0
cpath: /trunk/client
copyroot: 15280 /trunk

PLAIN
K 9
ABOUT-NLS
V 24
file fu.5ck.r23462/85000
K 7
AUTHORS
V 24
file 5u.5ck.r22143/14016
K 7
COPYING
V 19
file 1h.0.r9643/400
K 9
ChangeLog
V 26
file 6l.5ck.r22811/6091752
K 7
INSTALL
V 23
file 6.5ck.r23649/11556
K 11
Makefile.am
V 24
file 59.5ck.r23652/17731
K 4
NEWS
V 24
file 6m.5ck.r23374/75525
K 6
README
V 20
file 7.0.r4421/96382
K 2
ai
V 21
dir 8.5ck.r23666/4827
K 10
autogen.sh
V 24
file 12o.5ck.r23626/1124
K 9
bootstrap
V 23
dir 2p5.5ck.r23654/3702
K 6
client
V 22
dir d.5ck.r23687/72148
K 6
common
V 21
dir p.5ck.r23663/5098
K 12
configure.ac
V 24
file 149.5ck.r23685/4406
K 4
data
V 22
dir w.5ck.r23662/58235
K 6
debian
V 22
dir 5w.5ck.r23303/4506
K 12
dependencies
V 23
dir 2yu.5ck.r23272/7188
K 11
diff_ignore
V 24
file qq.5ck.r21039/26581
K 3
doc
V 23
dir k7.5ck.r23662/46135
K 10
fc_version
V 25
file 2lo.5en.r23662/43699
K 2
m4
V 23
dir 12p.5ck.r23672/2959
K 7
scripts
V 24
dir 2yo.5ck.r23535/11403
K 6
server
V 21
dir z.5ck.r23685/9192
K 5
tests
V 22
dir 2g9.5ck.r22096/825
K 5
tools
V 23
dir 4pj.5js.r23685/4174
K 12
translations
V 23
dir t0a.5ck.r23686/7062
K 7
utility
V 22
dir 1c.5ck.r23683/4848
K 3
vms
V 25
dir u9.5ck.r21528/1396085
K 5
win32
V 23
dir 2eu.5ck.r23679/3939
END
ENDREP
id: 3.5ck.r23687/73587
type: dir
pred: 3.5ck.r23686/8450
count: 16783
text: 23687 72377 1197 1197 be7dc4d2b6ae49e4c8f79c1559f8e779
props: 23244 4830 282 0 e4bb46e81629a60eef613b169b23a9ea
cpath: /trunk
copyroot: 15280 /trunk

PLAIN
K 8
branches
V 19
dir 1.0.r23682/8488
K 4
tags
V 20
dir 2.0.r23370/96893
K 5
trunk
V 22
dir 3.5ck.r23687/73587
K 7
website
V 21
dir 3ge.0.r22980/2263
END
ENDREP
id: 0.0.r23687/73980
type: dir
pred: 0.0.r23686/8841
count: 23687
text: 23687 73813 154 154 5b7484d871fb220869c3cd90d94a2f1a
cpath: /
copyroot: 0 /

6j1.5ck.t23686-1 modify true false /trunk/client/gui-qt/gui_main.cpp

6j8.5ck.t23686-1 modify true false /trunk/client/gui-qt/mapview.cpp

6ld.5ck.t23686-1 modify true false /trunk/client/gui-qt/fc_client.h

6ik.5ck.t23686-1 modify true false /trunk/client/gui-qt/citydlg.cpp

6il.5ck.t23686-1 modify true false /trunk/client/gui-qt/cityrep.cpp

6jg.5ck.t23686-1 modify true false /trunk/client/gui-qt/optiondlg.cpp

6ji.5ck.t23686-1 modify true false /trunk/client/gui-qt/pages.cpp

6js.5ck.t23686-1 modify true false /trunk/client/gui-qt/repodlgs.cpp

6ir.5ck.t23686-1 modify true false /trunk/client/gui-qt/dialogs.cpp

6j6.5ck.t23686-1 modify true false /trunk/client/gui-qt/mapctrl.cpp

6je.5ck.t23686-1 modify true false /trunk/client/gui-qt/messagewin.cpp

gr2.5ck.t23686-1 modify true false /trunk/client/gui-qt/citydlg.h

6ja.5ck.t23686-1 modify true false /trunk/client/gui-qt/menu.cpp

6jk.5ck.t23686-1 modify true false /trunk/client/gui-qt/plrdlg.cpp

6lc.5ck.t23686-1 modify true false /trunk/client/gui-qt/fc_client.cpp


73980 74129
