Debian Codegraph @

src/network/gamedialog.cpp

raw symbols SCIP
1 /***************************************************************************
2 * Copyright (C) 2009 by The qGo Project *
3 * *
4 * This file is part of qGo. *
5 * *
6 * qGo is free software: you can redistribute it and/or modify *
7 * it under the terms of the GNU General Public License as published by *
8 * the Free Software Foundation; either version 2 of the License, or *
9 * (at your option) any later version. *
10 * *
11 * This program is distributed in the hope that it will be useful, *
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14 * GNU General Public License for more details. *
15 * *
16 * You should have received a copy of the GNU General Public License *
17 * along with this program; if not, see <http://www.gnu.org/licenses/> *
18 * or write to the Free Software Foundation, Inc., *
19 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
20 ***************************************************************************/
21
22
23 #include "gamedialog.h"cxx . . $ `<file>/src/network/gamedialog.h`/
24 #include "audio.h"cxx . . $ `<file>/src/audio/audio.h`/
25
26 #include "defines.h"cxx . . $ `<file>/src/defines.h`/
27 //#include "komispinbox.h"
28 #include "network/networkconnection.h"cxx . . $ `<file>/src/network/networkconnection.h`/
29 #include "network/messages.h"cxx . . $ `<file>/src/network/messages.h`/
30 #include "network/gamedialogflags.h"cxx . . $ `<file>/src/network/gamedialogflags.h`/
31 #include "network/playergamelistings.h"cxx . . $ `<file>/src/network/playergamelistings.h`/
32
33
34 GameDialogcxx . . $ GameDialog#::GameDialogcxx . . $ GameDialog#GameDialog(7882215976d6ada).(NetworkConnectioncxx . . $ NetworkConnection# * conn, const PlayerListingcxx . . $ PlayerListing# * opp)
35 : QDialogcxx . . $ QDialog#QDialog(872e7b0c281abd8d).(), Uicxx . . $ Ui/::GameDialogcxx . . $ Ui/GameDialog#(), connectioncxx . . $ GameDialog#connection.(conn), opponentcxx . . $ GameDialog#opponent.(opp)
36 {
37 uicxx . . $ GameDialog#ui..setupUicxx . . $ Ui_GameDialog#setupUi(108f35f7aa7f3cf9).(this);
38 gameSoundcxx . . $ GameDialog#gameSound. = new Soundcxx . . $ Sound#Sound(6caa6e6871ecf3b).("blip.wav"cxx . . $ QString#QString(85c52e162fed56f9).);
39
40 setWindowTitlecxx . . $ QWidget#setWindowTitle(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("New Game"));
41
42 have_suggestdatacxx . . $ GameDialog#have_suggestdata. = false;
43 // komiSpin->setValue(55);
44 // buttonOffer->setFocus();
45 komi_requestcxx . . $ GameDialog#komi_request. = false;
46 is_nmatchcxx . . $ GameDialog#is_nmatch. = false;
47 offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused. = false;
48
49 dialog_changedcxx . . $ GameDialog#dialog_changed. = 0;
50 clearChangedFlagscxx . . $ GameDialog#clearChangedFlags(49f6e7a06ebc5aa8).();
51
52 current_match_requestcxx . . $ GameDialog#current_match_request. = new MatchRequestcxx . . $ MatchRequest#MatchRequest(49f6e7a06ebc5aa8).();
53
54 /* FIXME, what about size 38 and larger boards ?? */
55 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setRangecxx . . $ QSpinBox#setRange(3e454b8ccf442868).(1,19);
56 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setRangecxx . . $ QSpinBox#setRange(3e454b8ccf442868).(1,9);
57
58 we_are_challengercxx . . $ GameDialog#we_are_challenger. = false;
59
60 /* Not sure what to do with these. It would make sense to
61 * just have a number instead of a time spin since no seconds are
62 * allowed in two of the settings... but it would probably be better
63 * to set something on the timeSpin so that it still has the :00
64 * seconds reminder. Unless we want to have "seconds" in the text. */
65
66 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(connectioncxx . . $ GameDialog#connection.->gd_verifyBoardSizecxx . . $ NetworkConnection#gd_verifyBoardSize(7864480464b09eea).(preferencescxx . . $ preferences..default_sizecxx . . $ _preferences#default_size.));
67 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(preferencescxx . . $ preferences..default_komicxx . . $ _preferences#default_komi.);
68
69 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setDisplayFormatcxx . . $ QDateTimeEdit#setDisplayFormat(3520e46b33348bf6).("h:mm:ss"cxx . . $ QString#QString(85c52e162fed56f9).);
70 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setDisplayFormatcxx . . $ QDateTimeEdit#setDisplayFormat(3520e46b33348bf6).("h:mm:ss"cxx . . $ QString#QString(85c52e162fed56f9).);
71 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(canadiancxx . . $ canadian., qtimeFromSecondscxx . . $ GameDialog#qtimeFromSeconds(bc1d3073fb5de629).(preferencescxx . . $ preferences..default_stonesmaintimecxx . . $ _preferences#default_stonesmaintime.)));
72 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(canadiancxx . . $ canadian., QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, preferencescxx . . $ preferences..default_stonestimecxx . . $ _preferences#default_stonestime./60, preferencescxx . . $ preferences..default_stonestimecxx . . $ _preferences#default_stonestime.%60)));
73 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(canadiancxx . . $ canadian., preferencescxx . . $ preferences..default_stonescxx . . $ _preferences#default_stones.));
74 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(byoyomicxx . . $ byoyomi., QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, preferencescxx . . $ preferences..default_byomaintimecxx . . $ _preferences#default_byomaintime./60, preferencescxx . . $ preferences..default_byomaintimecxx . . $ _preferences#default_byomaintime.%60)));
75 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(byoyomicxx . . $ byoyomi., QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, preferencescxx . . $ preferences..default_byoperiodtimecxx . . $ _preferences#default_byoperiodtime./60, preferencescxx . . $ preferences..default_byoperiodtimecxx . . $ _preferences#default_byoperiodtime.%60)));
76 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(byoyomicxx . . $ byoyomi., preferencescxx . . $ preferences..default_byoperiodscxx . . $ _preferences#default_byoperiods.));
77 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(tvasiacxx . . $ tvasia., QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, preferencescxx . . $ preferences..default_asiamaintimecxx . . $ _preferences#default_asiamaintime./60, preferencescxx . . $ preferences..default_asiamaintimecxx . . $ _preferences#default_asiamaintime.%60)));
78 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(tvasiacxx . . $ tvasia., QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, preferencescxx . . $ preferences..default_asiaperiodtimecxx . . $ _preferences#default_asiaperiodtime./60, preferencescxx . . $ preferences..default_asiaperiodtimecxx . . $ _preferences#default_asiaperiodtime.%60)));
79 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(tvasiacxx . . $ tvasia., preferencescxx . . $ preferences..default_asiaperiodscxx . . $ _preferences#default_asiaperiods.));
80
81 // cb_free->setChecked(true);
82
83 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel., &QPushButtoncxx . . $ QPushButton#::pressedcxx . . $ QAbstractButton#pressed(49f6e7a06ebc5aa8)., this, &GameDialogcxx . . $ GameDialog#::slot_cancelcxx . . $ GameDialog#slot_cancel(49f6e7a06ebc5aa8).);
84 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline., &QPushButtoncxx . . $ QPushButton#::pressedcxx . . $ QAbstractButton#pressed(49f6e7a06ebc5aa8)., this, &GameDialogcxx . . $ GameDialog#::slot_declinecxx . . $ GameDialog#slot_decline(49f6e7a06ebc5aa8).);
85 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer., &QPushButtoncxx . . $ QPushButton#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., this, &GameDialogcxx . . $ GameDialog#::slot_offercxx . . $ GameDialog#slot_offer(b45ddcbc8423892c).);
86 //connect(ui.buttonStats,pressed()), slot_statsOpponent()));
87
88 // in order to check if anything changes
89 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..play_black_buttoncxx . . $ Ui_GameDialog#play_black_button., &QRadioButtoncxx . . $ QRadioButton#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., this, &GameDialogcxx . . $ GameDialog#::slot_play_black_buttoncxx . . $ GameDialog#slot_play_black_button(49f6e7a06ebc5aa8).);
90 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..play_white_buttoncxx . . $ Ui_GameDialog#play_white_button., &QRadioButtoncxx . . $ QRadioButton#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., this, &GameDialogcxx . . $ GameDialog#::slot_play_white_buttoncxx . . $ GameDialog#slot_play_white_button(49f6e7a06ebc5aa8).);
91 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..play_nigiri_buttoncxx . . $ Ui_GameDialog#play_nigiri_button., &QRadioButtoncxx . . $ QRadioButton#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., this, &GameDialogcxx . . $ GameDialog#::slot_play_nigiri_buttoncxx . . $ GameDialog#slot_play_nigiri_button(49f6e7a06ebc5aa8).);
92
93 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB., &QCheckBoxcxx . . $ QCheckBox#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., this, &GameDialogcxx . . $ GameDialog#::ratedCB_changedcxx . . $ GameDialog#ratedCB_changed(b45ddcbc8423892c).);
94 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_boardSizeSpincxx . . $ GameDialog#slot_boardSizeSpin(d4f767463ce0a6b3).);
95 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_handicapSpincxx . . $ GameDialog#slot_handicapSpin(d4f767463ce0a6b3).);
96 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_komiSpincxx . . $ GameDialog#slot_komiSpin(d4f767463ce0a6b3).);
97
98 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab., &QTabWidgetcxx . . $ QTabWidget#::currentChangedcxx . . $ QTabWidget#currentChanged(d4f767463ce0a6b3)., this, &GameDialogcxx . . $ GameDialog#::slot_timeTabcxx . . $ GameDialog#slot_timeTab(d4f767463ce0a6b3).);
99 // Does below need seconds or really only minutes??!?!? FIXME
100 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_timeSpincxx . . $ GameDialog#slot_timeSpin(49dbfc5ca47449c).);
101 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_stonesTimeSpincxx . . $ GameDialog#slot_stonesTimeSpin(49dbfc5ca47449c).);
102 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_stonesSpincxx . . $ GameDialog#slot_stonesSpin(d4f767463ce0a6b3).);
103 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_BYTimeSpincxx . . $ GameDialog#slot_BYTimeSpin(49dbfc5ca47449c).);
104 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_BYPeriodTimeSpincxx . . $ GameDialog#slot_BYPeriodTimeSpin(49dbfc5ca47449c).);
105 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_BYPeriodsSpincxx . . $ GameDialog#slot_BYPeriodsSpin(d4f767463ce0a6b3).);
106 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_ASIATimeSpincxx . . $ GameDialog#slot_ASIATimeSpin(49dbfc5ca47449c).);
107 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin., &QTimeEditcxx . . $ QTimeEdit#::timeChangedcxx . . $ QDateTimeEdit#timeChanged(49dbfc5ca47449c)., this, &GameDialogcxx . . $ GameDialog#::slot_ASIAPeriodTimeSpincxx . . $ GameDialog#slot_ASIAPeriodTimeSpin(49dbfc5ca47449c).);
108 connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin., QOverloadcxx . . $ QOverload#<int>::ofcxx . . $ QOverload#of(adaf930115d2ed26).(&QSpinBoxcxx . . $ QSpinBox#::valueChangedcxx . . $ QSpinBox#valueChanged(d4f767463ce0a6b3).), this, &GameDialogcxx . . $ GameDialog#::slot_ASIAPeriodsSpincxx . . $ GameDialog#slot_ASIAPeriodsSpin(d4f767463ce0a6b3).);
109 }
110
111 void GameDialogcxx . . $ GameDialog#::slot_play_black_buttoncxx . . $ GameDialog#slot_play_black_button(49f6e7a06ebc5aa8).(void)
112 {
113 if(current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. == MatchRequestcxx . . $ MatchRequest#::BLACKcxx . . $ MatchRequest#BLACK.)
114 {
115 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
116 color_request_changedcxx . . $ GameDialog#color_request_changed. = false;
117 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
118 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
119 }
120 else if(!color_request_changedcxx . . $ GameDialog#color_request_changed.)
121 {
122 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
123 color_request_changedcxx . . $ GameDialog#color_request_changed. = true;
124 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
125 }
126 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("play black: %d", dialog_changedcxx . . $ GameDialog#dialog_changed.);
127 if(flagscxx . . $ GameDialog#flags. & GDF_NIGIRI_EVENcxx . . $ `src/network/gamedialogflags.h:34:9`!)
128 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
129 }
130
131 void GameDialogcxx . . $ GameDialog#::slot_play_white_buttoncxx . . $ GameDialog#slot_play_white_button(49f6e7a06ebc5aa8).(void)
132 {
133 if(current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. == MatchRequestcxx . . $ MatchRequest#::WHITEcxx . . $ MatchRequest#WHITE.)
134 {
135 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
136 color_request_changedcxx . . $ GameDialog#color_request_changed. = false;
137 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
138 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
139 }
140 else
141 {
142 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
143 color_request_changedcxx . . $ GameDialog#color_request_changed. = true;
144 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
145 }
146 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("play white: %d", dialog_changedcxx . . $ GameDialog#dialog_changed.);
147 if(flagscxx . . $ GameDialog#flags. & GDF_NIGIRI_EVENcxx . . $ `src/network/gamedialogflags.h:34:9`!)
148 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
149 }
150
151 void GameDialogcxx . . $ GameDialog#::slot_play_nigiri_buttoncxx . . $ GameDialog#slot_play_nigiri_button(49f6e7a06ebc5aa8).(void)
152 {
153 if(current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. == MatchRequestcxx . . $ MatchRequest#::NIGIRIcxx . . $ MatchRequest#NIGIRI.)
154 {
155 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
156 color_request_changedcxx . . $ GameDialog#color_request_changed. = false;
157 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
158 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
159 }
160 else
161 {
162 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
163 color_request_changedcxx . . $ GameDialog#color_request_changed. = true;
164 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
165 }
166 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("play nigiri: %d", dialog_changedcxx . . $ GameDialog#dialog_changed.);
167 if(flagscxx . . $ GameDialog#flags. & GDF_NIGIRI_EVENcxx . . $ `src/network/gamedialogflags.h:34:9`!)
168 {
169 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(0);
170 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
171 }
172 }
173
174 void GameDialogcxx . . $ GameDialog#::ratedCB_changedcxx . . $ GameDialog#ratedCB_changed(b45ddcbc8423892c).(bool checked)
175 {
176 if((current_match_requestcxx . . $ GameDialog#current_match_request.->free_ratedcxx . . $ MatchRequest#free_rated. == RATEDcxx . . $ RATED.) == checked) //must have changed to get here
177 {
178 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
179 ratedchangedcxx . . $ GameDialog#ratedchanged. = false;
180 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
181 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
182 }
183 else if(!ratedchangedcxx . . $ GameDialog#ratedchanged.)
184 {
185 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
186 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
187 ratedchangedcxx . . $ GameDialog#ratedchanged. = true;
188 }
189
190 if(flagscxx . . $ GameDialog#flags. & GDF_RATED_SIZE_FIXEDcxx . . $ `src/network/gamedialogflags.h:31:9`!)
191 {
192 if(checked)
193 {
194 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("set disabled boardsize");
195 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(19);
196 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
197 }
198 else if(!(flagscxx . . $ GameDialog#flags. & GDF_ONLY_DISPUTE_TIMEcxx . . $ `src/network/gamedialogflags.h:35:9`!))
199 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
200 }
201 if(flagscxx . . $ GameDialog#flags. & GDF_RATED_HANDICAP_FIXEDcxx . . $ `src/network/gamedialogflags.h:32:9`!)
202 {
203 if(checked)
204 {
205 // We need to actually calculate the proper handicap
206 // FIXME
207 // with tygem its either 0 or 1 !!, anything else
208 // is automatically friendly
209 //ui.boardSizeSpin->setValue(19);
210 //ui.boardSizeSpin->setEnabled(false);
211 //for now
212 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
213 }
214 else if(!(flagscxx . . $ GameDialog#flags. & GDF_ONLY_DISPUTE_TIMEcxx . . $ `src/network/gamedialogflags.h:35:9`!))
215 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
216 }
217 if(flagscxx . . $ GameDialog#flags. & GDF_RATED_NO_HANDICAPcxx . . $ `src/network/gamedialogflags.h:33:9`!)
218 {
219 if(checked)
220 {
221 const PlayerListingcxx . . $ PlayerListing# * us = connectioncxx . . $ GameDialog#connection.->getOurListingcxx . . $ NetworkConnection#getOurListing(c84291d55c8466c6).();
222 getProperKomiHandicapcxx . . $ GameDialog#getProperKomiHandicap(a24a5210c7470c29).(uscxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., opponentcxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., &(current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi.), &(current_match_requestcxx . . $ GameDialog#current_match_request.->handicapcxx . . $ MatchRequest#handicap.));
223 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(current_match_requestcxx . . $ GameDialog#current_match_request.->handicapcxx . . $ MatchRequest#handicap.);
224 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).((int)(current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. - 0.5)); //.5 is added by dialog ui
225 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
226 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
227 }
228 else if(!(flagscxx . . $ GameDialog#flags. & GDF_ONLY_DISPUTE_TIMEcxx . . $ `src/network/gamedialogflags.h:35:9`!))
229 {
230 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
231 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
232 }
233 }
234 }
235
236 void GameDialogcxx . . $ GameDialog#::slot_boardSizeSpincxx . . $ GameDialog#slot_boardSizeSpin(d4f767463ce0a6b3).(int value)
237 {
238 int bs = connectioncxx . . $ GameDialog#connection.->gd_verifyBoardSizecxx . . $ NetworkConnection#gd_verifyBoardSize(7864480464b09eea).(value);
239 if(bs != value)
240 {
241 value = bs;
242 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(value);
243 }
244 if((int)current_match_requestcxx . . $ GameDialog#current_match_request.->board_sizecxx . . $ MatchRequest#board_size. == value) //must have changed to get here
245 {
246 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
247 boardSizechangedcxx . . $ GameDialog#boardSizechanged. = false;
248 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
249 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
250 }
251 else if(!boardSizechangedcxx . . $ GameDialog#boardSizechanged.)
252 {
253 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
254 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
255 boardSizechangedcxx . . $ GameDialog#boardSizechanged. = true;
256 }
257 }
258
259 /* Be careful!! there's a 1/0 issue here FIXME */
260 void GameDialogcxx . . $ GameDialog#::slot_handicapSpincxx . . $ GameDialog#slot_handicapSpin(d4f767463ce0a6b3).(int value)
261 {
262 if((int)current_match_requestcxx . . $ GameDialog#current_match_request.->handicapcxx . . $ MatchRequest#handicap. == value) //must have changed to get here
263 {
264 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
265 handicapchangedcxx . . $ GameDialog#handicapchanged. = false;
266 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
267 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
268 }
269 else if(!handicapchangedcxx . . $ GameDialog#handicapchanged.)
270 {
271 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
272 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
273 handicapchangedcxx . . $ GameDialog#handicapchanged. = true;
274 }
275 if(flagscxx . . $ GameDialog#flags. & GDF_KOMI_FIXED6cxx . . $ `src/network/gamedialogflags.h:39:9`!)
276 {
277 if(value == 0)
278 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(6);
279 else
280 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(0);
281 //already disabled
282 //ui.komiSpin->setEnabled(false);
283 }
284 else
285 {
286 /* We do this anyway, its just not disabled so it can be changed after */
287 if(value == 0)
288 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(6);
289 else
290 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(0);
291 }
292 }
293
294 void GameDialogcxx . . $ GameDialog#::slot_komiSpincxx . . $ GameDialog#slot_komiSpin(d4f767463ce0a6b3).(int value)
295 {
296 float komi = (float)value;
297 if(komi < 0)
298 komi -= 0.5;
299 else
300 komi += 0.5;
301 if(current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. == komi) //must have changed to get here
302 {
303 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
304 komichangedcxx . . $ GameDialog#komichanged. = false;
305 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
306 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
307 }
308 else if(!komichangedcxx . . $ GameDialog#komichanged.)
309 {
310 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
311 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
312 komichangedcxx . . $ GameDialog#komichanged. = true;
313 }
314 }
315
316 void GameDialogcxx . . $ GameDialog#::slot_timeTabcxx . . $ GameDialog#slot_timeTab(d4f767463ce0a6b3).(int value)
317 {
318 TimeSystemcxx . . $ TimeSystem# t;
319 switch(value)
320 {
321 case 0:
322 t = canadiancxx . . $ canadian.;
323 break;
324 case 1:
325 t = byoyomicxx . . $ byoyomi.;
326 break;
327 case 2:
328 t = tvasiacxx . . $ tvasia.;
329 break;
330 default:
331 t = nonecxx . . $ none.;
332 break;
333 }
334 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == t) //must have changed to get here
335 {
336 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
337 ttchangedcxx . . $ GameDialog#ttchanged. = false;
338 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
339 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
340 }
341 else if(!ttchangedcxx . . $ GameDialog#ttchanged.)
342 {
343 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
344 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
345 ttchangedcxx . . $ GameDialog#ttchanged. = true;
346 }
347 }
348
349 void GameDialogcxx . . $ GameDialog#::slot_timeSpincxx . . $ GameDialog#slot_timeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
350 {
351 //can't have seconds... ?
352 //if(v.seconds() > 0)
353 // ui.timeSpin->setTime(QTime(v.minutes(), 0);
354 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(canadiancxx . . $ canadian., v);
355 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
356 {
357 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
358 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
359 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
360 }
361 /*if(current_match_request->timeSystem == canadian)
362 {*/
363 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(v);
364 if(current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. == seconds)
365 {
366 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
367 timechangedcxx . . $ GameDialog#timechanged. = false;
368 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
369 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
370 }
371 else if(!timechangedcxx . . $ GameDialog#timechanged.)
372 {
373 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
374 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
375 timechangedcxx . . $ GameDialog#timechanged. = true;
376 }
377 //}
378 }
379
380 void GameDialogcxx . . $ GameDialog#::slot_stonesTimeSpincxx . . $ GameDialog#slot_stonesTimeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
381 {
382 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(canadiancxx . . $ canadian., v);
383 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
384 {
385 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
386 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
387 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
388 }
389 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == canadiancxx . . $ canadian.)
390 {
391 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(check);
392 if(current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. == seconds)
393 {
394 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
395 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
396 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
397 stonesTimechangedcxx . . $ GameDialog#stonesTimechanged. = false;
398 }
399 else if(!stonesTimechangedcxx . . $ GameDialog#stonesTimechanged.)
400 {
401 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
402 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
403 stonesTimechangedcxx . . $ GameDialog#stonesTimechanged. = true;
404 }
405 }
406 }
407
408 void GameDialogcxx . . $ GameDialog#::slot_stonesSpincxx . . $ GameDialog#slot_stonesSpin(d4f767463ce0a6b3).(int v)
409 {
410 unsigned int check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(canadiancxx . . $ canadian., v);
411 if(check != (unsigned)v)
412 {
413 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
414 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(check);
415 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
416 }
417 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == canadiancxx . . $ canadian.)
418 {
419 if(current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. == v)
420 {
421 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
422 stoneschangedcxx . . $ GameDialog#stoneschanged. = false;
423 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
424 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
425 }
426 else if(!stoneschangedcxx . . $ GameDialog#stoneschanged.)
427 {
428 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
429 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
430 stoneschangedcxx . . $ GameDialog#stoneschanged. = true;
431 }
432 }
433 }
434
435 void GameDialogcxx . . $ GameDialog#::slot_BYTimeSpincxx . . $ GameDialog#slot_BYTimeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
436 {
437 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(byoyomicxx . . $ byoyomi., v);
438 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
439 {
440 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
441 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
442 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
443 }
444 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == byoyomicxx . . $ byoyomi.)
445 {
446 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(v);
447 if(current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. == seconds)
448 {
449 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
450 timechangedcxx . . $ GameDialog#timechanged. = false;
451 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
452 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
453 }
454 else if(!timechangedcxx . . $ GameDialog#timechanged.)
455 {
456 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
457 timechangedcxx . . $ GameDialog#timechanged. = true;
458 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
459 }
460 }
461 }
462
463 void GameDialogcxx . . $ GameDialog#::slot_BYPeriodTimeSpincxx . . $ GameDialog#slot_BYPeriodTimeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
464 {
465 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(byoyomicxx . . $ byoyomi., v);
466 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
467 {
468 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
469 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
470 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
471 }
472 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == byoyomicxx . . $ byoyomi.)
473 {
474 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(v);
475 if(current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. == seconds)
476 {
477 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
478 BYPeriodTimechangedcxx . . $ GameDialog#BYPeriodTimechanged. = false;
479 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
480 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
481 }
482 else if(!BYPeriodTimechangedcxx . . $ GameDialog#BYPeriodTimechanged.)
483 {
484 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
485 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
486 BYPeriodTimechangedcxx . . $ GameDialog#BYPeriodTimechanged. = true;
487 }
488 }
489 }
490
491 void GameDialogcxx . . $ GameDialog#::slot_BYPeriodsSpincxx . . $ GameDialog#slot_BYPeriodsSpin(d4f767463ce0a6b3).(int v)
492 {
493 unsigned int check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(byoyomicxx . . $ byoyomi., v);
494 if(check != (unsigned)v)
495 {
496 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
497 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(check);
498 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
499 }
500 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == byoyomicxx . . $ byoyomi.)
501 {
502 if(current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. == v)
503 {
504 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
505 BYPeriodschangedcxx . . $ GameDialog#BYPeriodschanged. = false;
506 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
507 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
508 }
509 else if(!BYPeriodschangedcxx . . $ GameDialog#BYPeriodschanged.)
510 {
511 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
512 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
513 BYPeriodschangedcxx . . $ GameDialog#BYPeriodschanged. = true;
514 }
515 }
516 }
517
518 void GameDialogcxx . . $ GameDialog#::slot_ASIATimeSpincxx . . $ GameDialog#slot_ASIATimeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
519 {
520 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkMainTimecxx . . $ NetworkConnection#gd_checkMainTime(71240b9f3410da6b).(tvasiacxx . . $ tvasia., v);
521 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
522 {
523 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
524 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
525 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
526 }
527 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == tvasiacxx . . $ tvasia.)
528 {
529 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(v);
530 if(current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. == seconds)
531 {
532 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
533 ASIATimechangedcxx . . $ GameDialog#ASIATimechanged. = false;
534 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
535 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
536 }
537 else if(!ASIATimechangedcxx . . $ GameDialog#ASIATimechanged.)
538 {
539 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
540 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
541 ASIATimechangedcxx . . $ GameDialog#ASIATimechanged. = true;
542 }
543 }
544 }
545
546 void GameDialogcxx . . $ GameDialog#::slot_ASIAPeriodTimeSpincxx . . $ GameDialog#slot_ASIAPeriodTimeSpin(49dbfc5ca47449c).(const QTimecxx . . $ QTime# & v)
547 {
548 QTimecxx . . $ QTime# check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodTimecxx . . $ NetworkConnection#gd_checkPeriodTime(71240b9f3410da6b).(tvasiacxx . . $ tvasia., v);
549 if(check !=cxx . . $ QTime#`operator!=`(1610574c25194847). v)
550 {
551 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
552 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(check);
553 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
554 }
555 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == tvasiacxx . . $ tvasia.)
556 {
557 int seconds = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(v);
558 if(current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. == seconds)
559 {
560 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
561 ASIAPeriodTimechangedcxx . . $ GameDialog#ASIAPeriodTimechanged. = false;
562 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
563 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
564 }
565 else if(!ASIAPeriodTimechangedcxx . . $ GameDialog#ASIAPeriodTimechanged.)
566 {
567 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
568 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
569 ASIAPeriodTimechangedcxx . . $ GameDialog#ASIAPeriodTimechanged. = true;
570 }
571 }
572 }
573
574 void GameDialogcxx . . $ GameDialog#::slot_ASIAPeriodsSpincxx . . $ GameDialog#slot_ASIAPeriodsSpin(d4f767463ce0a6b3).(int v)
575 {
576 unsigned int check = connectioncxx . . $ GameDialog#connection.->gd_checkPeriodscxx . . $ NetworkConnection#gd_checkPeriods(c827b1ce4ef0d032).(tvasiacxx . . $ tvasia., v);
577 if(check != (unsigned)v)
578 {
579 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(true);
580 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(check);
581 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->blockSignalscxx . . $ QObject#blockSignals(4264aff4942d46ac).(false);
582 }
583 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. == tvasiacxx . . $ tvasia.)
584 {
585 if(current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. == v)
586 {
587 dialog_changedcxx . . $ GameDialog#dialog_changed.--;
588 ASIAPeriodschangedcxx . . $ GameDialog#ASIAPeriodschanged. = false;
589 if(dialog_changedcxx . . $ GameDialog#dialog_changed. == 0 && !current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
590 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
591 }
592 else if(!ASIAPeriodschangedcxx . . $ GameDialog#ASIAPeriodschanged.)
593 {
594 dialog_changedcxx . . $ GameDialog#dialog_changed.++;
595 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
596 ASIAPeriodschangedcxx . . $ GameDialog#ASIAPeriodschanged. = true;
597 }
598 }
599 }
600
601 void GameDialogcxx . . $ GameDialog#::clearChangedFlagscxx . . $ GameDialog#clearChangedFlags(49f6e7a06ebc5aa8).(void)
602 {
603 if(dialog_changedcxx . . $ GameDialog#dialog_changed. != 10000) //for offers
604 dialog_changedcxx . . $ GameDialog#dialog_changed. = 0;
605 color_request_changedcxx . . $ GameDialog#color_request_changed. = false;
606 ratedchangedcxx . . $ GameDialog#ratedchanged. = false;
607 boardSizechangedcxx . . $ GameDialog#boardSizechanged. = false;
608 handicapchangedcxx . . $ GameDialog#handicapchanged. = false;
609 komichangedcxx . . $ GameDialog#komichanged. = false;
610 ttchangedcxx . . $ GameDialog#ttchanged. = false;
611 timechangedcxx . . $ GameDialog#timechanged. = false;
612 stonesTimechangedcxx . . $ GameDialog#stonesTimechanged. = false;
613 stoneschangedcxx . . $ GameDialog#stoneschanged. = false;
614 BYPeriodTimechangedcxx . . $ GameDialog#BYPeriodTimechanged. = false;
615 BYPeriodschangedcxx . . $ GameDialog#BYPeriodschanged. = false;
616 ASIATimechangedcxx . . $ GameDialog#ASIATimechanged. = false;
617 ASIAPeriodTimechangedcxx . . $ GameDialog#ASIAPeriodTimechanged. = false;
618 ASIAPeriodschangedcxx . . $ GameDialog#ASIAPeriodschanged. = false;
619 }
620
621 GameDialogcxx . . $ GameDialog#::~cxx . . $ GameDialog#`~GameDialog`(ced63f7c635d850d).GameDialogcxx . . $ GameDialog#()
622 {
623 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("deconstructing GameDialog");
624 delete current_match_requestcxx . . $ GameDialog#current_match_request.;
625 }
626
627 void GameDialogcxx . . $ GameDialog#::closeEventcxx . . $ GameDialog#closeEvent(642e80679aeb34f8).(QCloseEventcxx . . $ QCloseEvent# *)
628 {
629 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("GameDialog::closeEvent");
630 if(connectioncxx . . $ GameDialog#connection.)
631 connectioncxx . . $ GameDialog#connection.->closeGameDialogcxx . . $ NetworkConnection#closeGameDialog(cac334474c82cf3a).(opponentcxx . . $ GameDialog#opponent.);
632 }
633
634 /*
635 void GameDialog::slot_opponentopen(const QString &opp)
636 {
637 qDebug("#### GameDialog::slot_opponentopen()");
638 if (playerOpponentEdit->text() != opp)//(playerWhiteEdit->isReadOnly() && playerBlackEdit->text() != opp || playerBlackEdit->isReadOnly() && playerWhiteEdit->text() != opp)
639 // not for me
640 return;
641
642 QString me;
643 QString opponent = playerOpponentEdit->text();;
644 // send match command, send tell:
645
646 // 24 *xxxx*: CLIENT: <qGo 1.9.12> match xxxx wants handicap 0, komi 0.5[, free]
647 // this command is not part of server preferences "use Komi" and "auto negotiation"
648 QString send = "tell " + opponent + " CLIENT: <qGo " + VERSION + "> match " +
649 me + " wants handicap " + ui.handicapSpin->text() + ", komi " +
650 komiSpin->text();
651 if (ComboBox_free->currentText() == QString(tr("yes")))
652 send += ", free";
653
654 emit signal_sendcommand(send, false);
655 }
656 */
657
658
659 /* This is used for offering and accepting */
660 void GameDialogcxx . . $ GameDialog#::slot_offercxx . . $ GameDialog#slot_offer(b45ddcbc8423892c).(bool active)
661 {
662 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("#### GameDialog::slot_offer()");
663 // active serves for more in the future...
664 // to clarify: active means the button is down and client is
665 // waiting on server response to offer
666 if (!active)
667 {
668 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("Not sending game offer, already active");
669 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(true); //since we just unchecked it
670 return;
671 }
672
673 offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused. = true;
674 save_to_preferencescxx . . $ GameDialog#save_to_preferences(49f6e7a06ebc5aa8).();
675 if(!dialog_changedcxx . . $ GameDialog#dialog_changed.)
676 {
677 if(current_match_requestcxx . . $ GameDialog#current_match_request.->first_offercxx . . $ MatchRequest#first_offer.)
678 connectioncxx . . $ GameDialog#connection.->sendMatchRequestcxx . . $ NetworkConnection#sendMatchRequest(969a5d62d7a1bd6e).(current_match_requestcxx . . $ GameDialog#current_match_request.);
679 else
680 connectioncxx . . $ GameDialog#connection.->acceptMatchOffercxx . . $ NetworkConnection#acceptMatchOffer(27875a747def42ce).(opponentcxx . . $ GameDialog#opponent., current_match_requestcxx . . $ GameDialog#current_match_request.);
681 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("Match request unchanged\n");
682 return;
683 }
684 // if both names are identical -> teaching game
685 if (uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). myNamecxx . . $ GameDialog#myName.)
686 {
687 /* FIXME I'm sure this teaching stuff is going to be buggy */
688 emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! signal_sendCommandcxx . . $ GameDialog#signal_sendCommand(37c160c81b6367f7).("teach " +cxx . . $ operator+(c75c3ae4eb9af1a8). uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->textcxx . . $ QAbstractSpinBox#text(6ef7b6c27b00b43d).(), false);
689 // prepare for future use...
690 //ui.buttonOffer->setDown(false);
691 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
692 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
693 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
694 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
695
696 //emit accept();
697 connectioncxx . . $ GameDialog#connection.->acceptMatchOffercxx . . $ NetworkConnection#acceptMatchOffer(27875a747def42ce).(opponentcxx . . $ GameDialog#opponent., current_match_requestcxx . . $ GameDialog#current_match_request.);
698 return;
699 }
700
701 // send match command
702 // below nigiri shouldn't be checked if not possible
703 if (uicxx . . $ GameDialog#ui..play_white_buttoncxx . . $ Ui_GameDialog#play_white_button.->isCheckedcxx . . $ QAbstractButton#isChecked(50ce9a9e25b4a850).())
704 {
705 current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. = MatchRequestcxx . . $ MatchRequest#::WHITEcxx . . $ MatchRequest#WHITE.;
706 //FIXME maybe check here if we're the challenger???
707 //current_match_request->challenger_is_black = 0;
708 }
709 else if(uicxx . . $ GameDialog#ui..play_black_buttoncxx . . $ Ui_GameDialog#play_black_button.->isCheckedcxx . . $ QAbstractButton#isChecked(50ce9a9e25b4a850).())
710 {
711 current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. = MatchRequestcxx . . $ MatchRequest#::BLACKcxx . . $ MatchRequest#BLACK.;
712 //current_match_request->challenger_is_black = 1;
713 }
714 else if (uicxx . . $ GameDialog#ui..play_nigiri_buttoncxx . . $ Ui_GameDialog#play_nigiri_button.->isCheckedcxx . . $ QAbstractButton#isChecked(50ce9a9e25b4a850).() /*&& is_nmatch*/) //what is this nmatch stuff ??? FIXME
715 {
716 current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request. = MatchRequestcxx . . $ MatchRequest#::NIGIRIcxx . . $ MatchRequest#NIGIRI.;
717 //current_match_request->challenger_is_black = 0;
718 }
719 if(uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->isCheckedcxx . . $ QAbstractButton#isChecked(50ce9a9e25b4a850).())
720 current_match_requestcxx . . $ GameDialog#current_match_request.->free_ratedcxx . . $ MatchRequest#free_rated. = RATEDcxx . . $ RATED.;
721 else
722 current_match_requestcxx . . $ GameDialog#current_match_request.->free_ratedcxx . . $ MatchRequest#free_rated. = FREEcxx . . $ FREE.;
723 current_match_requestcxx . . $ GameDialog#current_match_request.->board_sizecxx . . $ MatchRequest#board_size. = uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
724 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("bs value: %d", current_match_requestcxx . . $ GameDialog#current_match_request.->board_sizecxx . . $ MatchRequest#board_size.);
725 current_match_requestcxx . . $ GameDialog#current_match_request.->handicapcxx . . $ MatchRequest#handicap. = uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->cleanTextcxx . . $ QSpinBox#cleanText(6ef7b6c27b00b43d).().toIntcxx . . $ QString#toInt(d7972accae11ee1f).();
726 current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. = (float)uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
727 if(current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. > 0)
728 current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. += 0.5;
729 else
730 current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi. -= 0.5;
731 /* According to ui form, there's only two time fields and according to existing code
732 * and IGS parser code, there's only canadian time... so we'll go with that for now.
733 * I am now certain that "nmatch" means byoyomi according to IGS... so why
734 * the comment below: "25 stones_periods hard coded: bad ??? FIXME */
735 if(uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->currentIndexcxx . . $ QTabWidget#currentIndex(455f465bc33b4cdf).() == 0) //canadian or is it in IGS???
736 {
737 //FIXME, really its nmatch for IGS if we support nmatch and
738 //opponent does as well
739 //current_match_request->nmatch = false;
740 current_match_requestcxx . . $ GameDialog#current_match_request.->nmatchcxx . . $ MatchRequest#nmatch. = true;
741 current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).());
742 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. = (uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60);
743 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. += uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
744 current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. = uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
745 current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. = canadiancxx . . $ canadian.;
746 }
747 else if(uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->currentIndexcxx . . $ QTabWidget#currentIndex(455f465bc33b4cdf).() == 1) //byo yomi IGS nmatch
748 {
749 current_match_requestcxx . . $ GameDialog#current_match_request.->nmatchcxx . . $ MatchRequest#nmatch. = true;
750 current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).());
751 if(!(flagscxx . . $ GameDialog#flags. & GDF_BY_CAN_MAIN_MINcxx . . $ `src/network/gamedialogflags.h:36:9`!)) //ugly FIXME
752 current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. += uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
753 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. = (uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60);
754 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. += uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
755 current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. = uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
756 current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. = byoyomicxx . . $ byoyomi.;
757 }
758 else if(uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->currentIndexcxx . . $ QTabWidget#currentIndex(455f465bc33b4cdf).() == 2) //tv asia, ORO
759 {
760 current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime. = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).());
761 /* We can have more than 60 seconds... like 300 FIXME */
762 //current_match_request->maintime = (ui.ASIATimeSpin->time().minute() * 60);
763 //current_match_request->maintime += ui.ASIATimeSpin->time().second();
764 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. = (uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60);
765 current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime. += uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
766 current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods. = uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
767 current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. = tvasiacxx . . $ tvasia.;
768 }
769
770 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("Match request changed %d\n", dialog_changedcxx . . $ GameDialog#dialog_changed.);
771 connectioncxx . . $ GameDialog#connection.->sendMatchRequestcxx . . $ NetworkConnection#sendMatchRequest(969a5d62d7a1bd6e).(current_match_requestcxx . . $ GameDialog#current_match_request.);
772 /* FIXME
773 * I'm pretty sure that we want to SetPalette on all the mutable ui
774 * elements to the app default when we hit offer. But we should
775 * double check this behavior, see if it makes sense.*/
776 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
777 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
778 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
779 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
780 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
781 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
782 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
783 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
784 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
785 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
786 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
787 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
788 }
789
790 void GameDialogcxx . . $ GameDialog#::slot_declinecxx . . $ GameDialog#slot_decline(49f6e7a06ebc5aa8).()
791 {
792 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("#### GameDialog::slot_decline()");
793
794 //QString opponent = ui.playerOpponentEdit->text();//(playerWhiteEdit->isReadOnly() ? playerBlackEdit->text():playerWhiteEdit->text());
795
796 #ifdef FIXME
797 if (ui.buttonOffer->isDown())
798 {
799 // match has been offered
800 // !! there seem to be not "setOn" in the code (apart init, but this should not reach this code)
801 qDebug("GameDialog::slot_decline sends withdraw (not IGS)");
802 emit signal_sendCommand("withdraw", false);
803 //ui.buttonOffer->setDown(false);
804 ui.buttonOffer->setChecked(false);
805 ui.buttonOffer->setText(tr("Offer"));
806 }
807 #endif //FIXME
808 /* FIXME this is also sending a lot of unnecessary declines in IGS.
809 * like maybe we only need to send an IGS decline if there's been an offer
810 * and a counter offer. But what if you offer a game and then cancel
811 * the offer? Maybe you can't... we could check for the decline text
812 * on the button as well, but then what exactly is the flag for...
813 * confusing...*/
814 if(offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused.) //FIXME decline button shouldn't be possible otherwise
815 connectioncxx . . $ GameDialog#connection.->declineMatchOffercxx . . $ NetworkConnection#declineMatchOffer(cac334474c82cf3a).(opponentcxx . . $ GameDialog#opponent.);
816
817 closecxx . . $ QWidget#close(c9857a73d68e59ba).();
818 }
819
820 void GameDialogcxx . . $ GameDialog#::slot_cancelcxx . . $ GameDialog#slot_cancel(49f6e7a06ebc5aa8).()
821 {
822 if(offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused. && uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->isEnabledcxx . . $ QWidget#isEnabled(50ce9a9e25b4a850).())
823 connectioncxx . . $ GameDialog#connection.->declineMatchOffercxx . . $ NetworkConnection#declineMatchOffer(cac334474c82cf3a).(opponentcxx . . $ GameDialog#opponent.);
824 else if(uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->isEnabledcxx . . $ QWidget#isEnabled(50ce9a9e25b4a850).() && uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->textcxx . . $ QAbstractButton#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"))
825 connectioncxx . . $ GameDialog#connection.->cancelMatchOffercxx . . $ NetworkConnection#cancelMatchOffer(cac334474c82cf3a).(opponentcxx . . $ GameDialog#opponent.);
826 closecxx . . $ QWidget#close(c9857a73d68e59ba).();
827 }
828
829 //TODO : not used now
830 void GameDialogcxx . . $ GameDialog#::slot_changedcxx . . $ GameDialog#slot_changed(49f6e7a06ebc5aa8).()
831 {
832 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("#### GameDialog::slot_changed()");
833 if (uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). myNamecxx . . $ GameDialog#myName.)// playerBlackEdit->text())
834 {
835 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Teaching"));
836 // ComboBox_free->setEnabled(false);
837
838 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
839 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
840 }
841 else
842 {
843 //ui.buttonOffer->setText(tr("Offer"));
844 // ComboBox_free->setEnabled(true);
845
846 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
847 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
848 }
849
850 // check for free game
851 if (uicxx . . $ GameDialog#ui..playerOpponentRkEditcxx . . $ Ui_GameDialog#playerOpponentRkEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ QString#`operator==`(7d4bdb1abc417636). "NR" || myRkcxx . . $ GameDialog#myRk. ==cxx . . $ QString#`operator==`(7d4bdb1abc417636). "NR" || uicxx . . $ GameDialog#ui..playerOpponentRkEditcxx . . $ Ui_GameDialog#playerOpponentRkEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). myRkcxx . . $ GameDialog#myRk.)
852 {
853 // ComboBox_free->setCurrentItem(1);
854 }
855 else
856 {
857 // ComboBox_free->setEnabled(true);
858 }
859 // FIXME
860 //ui.buttonOffer->setDown(false);
861 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
862 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer")); //counter?
863 }
864
865 void GameDialogcxx . . $ GameDialog#::recvRefuseMatchcxx . . $ GameDialog#recvRefuseMatch(d4f767463ce0a6b3).(int motive)
866 {
867 if (motive == GD_REFUSE_NOTOPENcxx . . $ `src/network/networkconnection.h:79:9`!)
868 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1 not open for matches").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
869 else if (motive == GD_REFUSE_DECLINEcxx . . $ `src/network/networkconnection.h:80:9`!)
870 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1 declined the match request").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
871 else if (motive == GD_REFUSE_CANCELcxx . . $ `src/network/networkconnection.h:81:9`!)
872 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1 canceled the match request").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
873 else if (motive == GD_REFUSE_INGAMEcxx . . $ `src/network/networkconnection.h:82:9`!)
874 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1 already playing a game").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
875 else if(motive == GD_REFUSE_NODIRECTcxx . . $ `src/network/networkconnection.h:83:9`!)
876 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1 does not accept direct matches").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
877 else if(motive == GD_OPP_NO_NMATCHcxx . . $ `src/network/networkconnection.h:85:9`!)
878 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("%1's client does not support nmatch").argcxx . . $ QString#arg(bc823072288cbbb5).(opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.));
879 else if(motive == GD_INVALID_PARAMETERScxx . . $ `src/network/networkconnection.h:84:9`!)
880 {
881 uicxx . . $ GameDialog#ui..refusedLabelcxx . . $ Ui_GameDialog#refusedLabel.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Invalid Parameters!"));
882 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
883 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
884 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
885 return;
886 }
887 else if(motive == GD_RESETcxx . . $ `src/network/networkconnection.h:86:9`!)
888 {
889 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
890 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
891 return;
892 }
893 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("#### GameDialog::slot_notopen()");
894 if (opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name..isEmptycxx . . $ QString#isEmpty(50ce9a9e25b4a850).()) //FIXME
895 {
896 // IGS: no player named -> check if offering && focus set
897 if (uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->isCheckedcxx . . $ QAbstractButton#isChecked(50ce9a9e25b4a850).())// && QWidget::hasFocus())
898 {
899
900 // ui.buttonOffer->setDown(false);
901 // ui.buttonOffer->setText(tr("Offer"));
902 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
903 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
904 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
905 }
906 }
907 else if (uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.)//(playerWhiteEdit->isReadOnly() && playerBlackEdit->text() == opponent || playerBlackEdit->isReadOnly() && playerWhiteEdit->text() == opponent)
908 {
909
910 // ui.buttonOffer->setDown(false);
911 // ui.buttonOffer->setText(tr("Offer"));
912 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
913 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
914 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
915 }
916 offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused. = false;
917 }
918
919 // if opponent has requestet for handicap, komi and/or free game
920 void GameDialogcxx . . $ GameDialog#::slot_komiRequestcxx . . $ GameDialog#slot_komiRequest(7ae16150a604556).(const QStringcxx . . $ QString# &opponent, int h, int k, bool /*free*/)
921 {
922 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("#### GameDialog::slot_komirequest()");
923 if (uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->textcxx . . $ QLineEdit#text(6ef7b6c27b00b43d).() ==cxx . . $ `operator==`(5bc2975d2d751687). opponent)
924 {
925
926 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(h);
927
928 komi_requestcxx . . $ GameDialog#komi_request. = true; //the komi checkbox has been replaced by
929 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(k);
930
931 // if (free)
932 // ComboBox_free->setCurrentItem(1);
933 // else
934 // ComboBox_free->setCurrentItem(0);
935
936 // ui.buttonOffer->setText(tr("Accept"));
937 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setDowncxx . . $ QAbstractButton#setDown(b45ddcbc8423892c).(false);
938 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
939 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
940 }
941 else
942 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
943 }
944
945 /* If there's an existing match request, we need to highlight the changes */
946 void GameDialogcxx . . $ GameDialog#::recvRequestcxx . . $ GameDialog#recvRequest(461bc273ee812ab9).(MatchRequestcxx . . $ MatchRequest# * mr, unsigned long _flags)
947 {
948 bool destroy_other_timetabs = false;
949 bool this_is_offer = false;
950 /* A little iffy here. We might want to get the flags
951 * every request, but it also might be that we don't
952 * want to have them handy, so we just want to set them
953 * once the first time */
954 if(_flags)
955 {
956 flagscxx . . $ GameDialog#flags. = _flags;
957 if(!(flagscxx . . $ GameDialog#flags. & GDF_CANADIANcxx . . $ `src/network/gamedialogflags.h:26:9`!))
958 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(0, false);
959 if(!(flagscxx . . $ GameDialog#flags. & GDF_BYOYOMIcxx . . $ `src/network/gamedialogflags.h:27:9`!))
960 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(1, false);
961 /* We remove ASIA because its the last tab.
962 * this is rather unfortunately, we need names
963 * for the tabs, FIXME, otherwise it screws
964 * the indexes up to delete the tabs */
965 if(!(flagscxx . . $ GameDialog#flags. & GDF_TVASIAcxx . . $ `src/network/gamedialogflags.h:28:9`!))
966 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->removeTabcxx . . $ QTabWidget#removeTab(d4f767463ce0a6b3).(2);
967
968 if(!(flagscxx . . $ GameDialog#flags. & GDF_FREE_RATED_CHOICEcxx . . $ `src/network/gamedialogflags.h:30:9`!))
969 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
970 if((flagscxx . . $ GameDialog#flags. & GDF_RATED_NO_HANDICAPcxx . . $ `src/network/gamedialogflags.h:33:9`!) && (!mr || mr->free_ratedcxx . . $ MatchRequest#free_rated. == RATEDcxx . . $ RATED.))
971 {
972 const PlayerListingcxx . . $ PlayerListing# * us = connectioncxx . . $ GameDialog#connection.->getOurListingcxx . . $ NetworkConnection#getOurListing(c84291d55c8466c6).();
973 float k;
974 unsigned int h;
975 getProperKomiHandicapcxx . . $ GameDialog#getProperKomiHandicap(a24a5210c7470c29).(uscxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., opponentcxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., &k, &h);
976 if(h > 1)
977 {
978 //mr->free_rated = FREE; //necessary?? FIXME
979 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
980 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
981 }
982 }
983 if((flagscxx . . $ GameDialog#flags. & GDF_STONES25_FIXEDcxx . . $ `src/network/gamedialogflags.h:29:9`!) && !mr)
984 {
985 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(25);
986 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
987 }
988
989 /* We can actually ignore this with ORO, change
990 * and send whatever we want, but I feel like its
991 * cheap to the opponent who doesn't even see
992 * the changes */
993 if((flagscxx . . $ GameDialog#flags. & GDF_ONLY_DISPUTE_TIMEcxx . . $ `src/network/gamedialogflags.h:35:9`!) && mr)
994 {
995 /* I don't like the color of this gray
996 * FIXME. It looks more like an option
997 * that's removed rather than something
998 * that you're not allowed to change */
999 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1000 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1001 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1002 uicxx . . $ GameDialog#ui..play_black_buttoncxx . . $ Ui_GameDialog#play_black_button.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1003 uicxx . . $ GameDialog#ui..play_white_buttoncxx . . $ Ui_GameDialog#play_white_button.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1004 uicxx . . $ GameDialog#ui..play_nigiri_buttoncxx . . $ Ui_GameDialog#play_nigiri_button.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1005 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1006
1007 destroy_other_timetabs = true;
1008 }
1009 /* As far as I know, no protocols allow time systems
1010 * with main time in seconds except TVASIA and there's
1011 * also ranges on these things. We need flags for that
1012 * as well FIXME */
1013 /* Note that we still FIXME need a flag for things like
1014 * 10 second increments and the like.
1015 * Also, it doesn't like more than two mm, or two ss
1016 * which means we need hours I guess and I wonder if
1017 * that's clear and then maybe we need a "seconds"
1018 * on the label. FIXME.*/
1019 if(flagscxx . . $ GameDialog#flags. & GDF_BY_CAN_MAIN_MINcxx . . $ `src/network/gamedialogflags.h:36:9`!)
1020 {
1021 //ui.timeSpin->setDisplayFormat("mmm");
1022 //ui.BYTimeSpin->setDisplayFormat("mmm");
1023 }
1024 //ui.ASIATimeSpin->setDisplayFormat("sss");
1025 if((flagscxx . . $ GameDialog#flags. & GDF_KOMI_FIXED6cxx . . $ `src/network/gamedialogflags.h:39:9`!) && !mr)
1026 {
1027 if(uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).() == 0)
1028 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(6);
1029 else
1030 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(0);
1031 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1032 }
1033 if(mr)
1034 {
1035 #ifdef FIXME
1036 if(mr->timeSystem == canadian)
1037 {
1038 //is min 0 or is it the current ? FIXME
1039 if(mr->nmatch_timeMax)
1040 ui.timeSpin->setTimeRange(qtimeFromSeconds(0), qtimeFromSeconds(mr->nmatch_timeMax));
1041 //ui.timeSpin->setTimeRange(qtimeFromSeconds(mr->maintime), qtimeFromSeconds(mr->nmatch_timeMax));
1042 if(mr->nmatch_BYMax)
1043 ui.stonesTimeSpin->setTimeRange(qtimeFromSeconds(0), qtimeFromSeconds(mr->nmatch_BYMax));
1044 //ui.stonesTimeSpin->setTimeRange(qtimeFromSeconds(mr->periodtime), qtimeFromSeconds(mr->nmatch_BYMax));
1045 }
1046 else if(mr->timeSystem == byoyomi)
1047 {
1048 if(mr->nmatch_timeMax)
1049 ui.BYTimeSpin->setTimeRange(QTime(0, mr->maintime/60, 0), QTime(0, mr->nmatch_timeMax/60, 0));
1050 if(mr->nmatch_BYMax)
1051 ui.BYPeriodTimeSpin->setTimeRange(QTime(0, mr->periodtime/60, 0), QTime(0, mr->nmatch_BYMax/60, 0));
1052 }
1053 if(mr->nmatch_handicapMax)
1054 ui.handicapSpin->setRange(mr->handicap, mr->nmatch_handicapMax);
1055 #endif //FIXME
1056 //not necessarily: !!! FIXME
1057 //we_are_challenger = true;
1058 //this_is_offer = true;
1059 }
1060 }
1061 if(!mr)
1062 {
1063 /* FIXME FIXME FIXME
1064 * if this is the open of the dialog,
1065 * we need to fill out the current_match_request,
1066 * otherwise it gets sent as uninitialized garbage!!
1067 * at least sometimes */
1068 //load defaults
1069 //mr->time = preferences.default_maintime;
1070 //mr->board_size = preferences.default_boardsize;
1071 //etc...
1072 // FIXME
1073 mr = new MatchRequestcxx . . $ MatchRequest#MatchRequest(49f6e7a06ebc5aa8).();
1074 const PlayerListingcxx . . $ PlayerListing# * us = connectioncxx . . $ GameDialog#connection.->getOurListingcxx . . $ NetworkConnection#getOurListing(c84291d55c8466c6).();
1075 mr->opponentcxx . . $ MatchRequest#opponent. =cxx . . $ QString#`operator=`(b79fde0b0ce9b948). opponentcxx . . $ GameDialog#opponent.->namecxx . . $ PlayerListing#name.;
1076 mr->opponent_idcxx . . $ MatchRequest#opponent_id. = opponentcxx . . $ GameDialog#opponent.->idcxx . . $ PlayerListing#id.;
1077 mr->their_rankcxx . . $ MatchRequest#their_rank. =cxx . . $ QString#`operator=`(b79fde0b0ce9b948). opponentcxx . . $ GameDialog#opponent.->rankcxx . . $ PlayerListing#rank.;
1078 mr->our_namecxx . . $ MatchRequest#our_name. =cxx . . $ QString#`operator=`(b79fde0b0ce9b948). us->namecxx . . $ PlayerListing#name.;
1079 mr->our_rankcxx . . $ MatchRequest#our_rank. =cxx . . $ QString#`operator=`(b79fde0b0ce9b948). us->rankcxx . . $ PlayerListing#rank.; //us.rank sounds like bad grammar
1080 mr->timeSystemcxx . . $ MatchRequest#timeSystem. = canadiancxx . . $ canadian.;
1081 mr->maintimecxx . . $ MatchRequest#maintime. = 600;
1082 mr->periodtimecxx . . $ MatchRequest#periodtime. = 600;
1083 mr->stones_periodscxx . . $ MatchRequest#stones_periods. = 25;
1084 if(getProperKomiHandicapcxx . . $ GameDialog#getProperKomiHandicap(a24a5210c7470c29).(uscxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., opponentcxx . . $ QString#QString(132dd6869045752b).->rankcxx . . $ PlayerListing#rank., &(mr->komicxx . . $ MatchRequest#komi.), &(mr->handicapcxx . . $ MatchRequest#handicap.)))
1085 {
1086 //challenger is black is a mystery byte
1087 //I'm thinking it might be whether the request is
1088 // modifiable, or if our only answer is to accept
1089 // or decline, okay, nevermind, its not modification...
1090 // FIXME
1091 mr->challenger_is_blackcxx . . $ MatchRequest#challenger_is_black. = 1;
1092 mr->color_requestcxx . . $ MatchRequest#color_request. = MatchRequestcxx . . $ MatchRequest#::BLACKcxx . . $ MatchRequest#BLACK.;
1093 }
1094 else
1095 {
1096 mr->challenger_is_blackcxx . . $ MatchRequest#challenger_is_black. = 1;
1097 mr->color_requestcxx . . $ MatchRequest#color_request. = MatchRequestcxx . . $ MatchRequest#::WHITEcxx . . $ MatchRequest#WHITE.;
1098 }
1099 if(mr->handicapcxx . . $ MatchRequest#handicap. == 1 && !(flagscxx . . $ GameDialog#flags. & GDF_HANDICAP1cxx . . $ `src/network/gamedialogflags.h:37:9`!))
1100 mr->handicapcxx . . $ MatchRequest#handicap. = 0;
1101 we_are_challengercxx . . $ GameDialog#we_are_challenger. = true;
1102 this_is_offer = true;
1103 /* FIXME, a lot of stuff to fill in here, defaults and the
1104 * like to make it kosher across the board */
1105 mr->flagscxx . . $ MatchRequest#flags. = 0xf0; //FIXME for now
1106 mr->numbercxx . . $ MatchRequest#number. = connectioncxx . . $ GameDialog#connection.->getRoomNumbercxx . . $ NetworkConnection#getRoomNumber(32a7769d58713265).();
1107 mr->opponent_is_challengercxx . . $ MatchRequest#opponent_is_challenger. = false;
1108 mr->first_offercxx . . $ MatchRequest#first_offer. = true;
1109 //mr->free_rated = FREE;
1110 mr->free_ratedcxx . . $ MatchRequest#free_rated. = RATEDcxx . . $ RATED.; /* its more typically rated by default, but we should get this from somewhere FIXME */
1111 mr->nmatchcxx . . $ MatchRequest#nmatch. = true; //igs
1112 current_match_requestcxx . . $ GameDialog#current_match_request.->nmatchcxx . . $ MatchRequest#nmatch. = mr->nmatchcxx . . $ MatchRequest#nmatch.; //awkward, but not set anywhere else
1113 dialog_changedcxx . . $ GameDialog#dialog_changed. = 10000; //so it can't be anything but "Offer"
1114 }
1115 else
1116 {
1117 if(mr->first_offercxx . . $ MatchRequest#first_offer.)
1118 {
1119 this_is_offer = true;
1120 dialog_changedcxx . . $ GameDialog#dialog_changed. = 10000; //so it can't be anything but "Offer"
1121 //FIXME should be in one place, also, this FORCES us
1122 //to call recvRequest after getGameDialog
1123 //the whole thing is awkward and now that we have most
1124 //of the protocols figured out it should be cleaned up
1125 //also, this may not be necessary, it didn't fix the problem
1126 //FIXME
1127 }
1128 else
1129 offered_and_unrefusedcxx . . $ GameDialog#offered_and_unrefused. = true;
1130 }
1131 /* I think above is right... so if its a default that we haven't offered yet,
1132 * then offered_and_unrefused is left off, but if its from them, then we
1133 * can send decline. We also send a decline after we offer which is
1134 * a little weird... I mean either they accept it and there's a game, or
1135 * they change it and then we'd alter offered_and_unrefused here.
1136 * probably FIXME, I just wonder why its like that in the first place */
1137
1138 QPalettecxx . . $ QPalette# p(QApplicationcxx . . $ QApplication#::palettecxx . . $ QApplication#palette(522fbdbbff1b5a68).());
1139 p.setColorcxx . . $ QPalette#setColor(4fd5272df43acd68).( QPalettecxx . . $ QPalette#::Basecxx . . $ QPalette#Base. , QColorcxx . . $ QColor#QColor(85c52e162fed56f9).("cyan"));
1140
1141 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("GameDialog::recvRequest");
1142 /* If there's no existing request, then nothing should have changed
1143 * opponent can't change, so that's the check. */
1144 if(current_match_requestcxx . . $ GameDialog#current_match_request.->opponentcxx . . $ MatchRequest#opponent. !=cxx . . $ `operator!=`(5bc2975d2d751687). mr->opponentcxx . . $ MatchRequest#opponent.)
1145 *current_match_requestcxx . . $ GameDialog#current_match_request. =cxx . . $ MatchRequest#`operator=`(192481a576b2c65a). *mr;
1146
1147
1148 set_oppRkcxx . . $ GameDialog#set_oppRk(4c89b026053e4d32).(mr->their_rankcxx . . $ MatchRequest#their_rank.);
1149
1150 set_myRkcxx . . $ GameDialog#set_myRk(4c89b026053e4d32).(mr->our_rankcxx . . $ MatchRequest#our_rank.);
1151
1152 uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).(mr->opponentcxx . . $ MatchRequest#opponent.);
1153 uicxx . . $ GameDialog#ui..playerOpponentEditcxx . . $ Ui_GameDialog#playerOpponentEdit.->setReadOnlycxx . . $ QLineEdit#setReadOnly(b45ddcbc8423892c).(true);
1154 uicxx . . $ GameDialog#ui..playerOpponentRkEditcxx . . $ Ui_GameDialog#playerOpponentRkEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).(mr->their_rankcxx . . $ MatchRequest#their_rank.);
1155 set_myNamecxx . . $ GameDialog#set_myName(4c89b026053e4d32).(mr->our_namecxx . . $ MatchRequest#our_name.);
1156
1157 if(mr->free_ratedcxx . . $ MatchRequest#free_rated. != current_match_requestcxx . . $ GameDialog#current_match_request.->free_ratedcxx . . $ MatchRequest#free_rated.)
1158 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1159 if(mr->free_ratedcxx . . $ MatchRequest#free_rated. == RATEDcxx . . $ RATED.)
1160 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(true);
1161 else
1162 uicxx . . $ GameDialog#ui..ratedCBcxx . . $ Ui_GameDialog#ratedCB.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
1163 ratedCB_changedcxx . . $ GameDialog#ratedCB_changed(b45ddcbc8423892c).((mr->free_ratedcxx . . $ MatchRequest#free_rated. == RATEDcxx . . $ RATED.));
1164
1165 /* These may have rated fixed issues as well */
1166 switch(mr->color_requestcxx . . $ MatchRequest#color_request.)
1167 {
1168 case MatchRequestcxx . . $ MatchRequest#::BLACKcxx . . $ MatchRequest#BLACK.:
1169 uicxx . . $ GameDialog#ui..play_black_buttoncxx . . $ Ui_GameDialog#play_black_button.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(true);
1170 if(mr->color_requestcxx . . $ MatchRequest#color_request. != current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request.)
1171 uicxx . . $ GameDialog#ui..play_black_buttoncxx . . $ Ui_GameDialog#play_black_button.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1172 slot_play_black_buttoncxx . . $ GameDialog#slot_play_black_button(49f6e7a06ebc5aa8).();
1173 break;
1174 case MatchRequestcxx . . $ MatchRequest#::WHITEcxx . . $ MatchRequest#WHITE.:
1175 uicxx . . $ GameDialog#ui..play_white_buttoncxx . . $ Ui_GameDialog#play_white_button.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(true);
1176 if(mr->color_requestcxx . . $ MatchRequest#color_request. != current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request.)
1177 uicxx . . $ GameDialog#ui..play_white_buttoncxx . . $ Ui_GameDialog#play_white_button.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1178 slot_play_white_buttoncxx . . $ GameDialog#slot_play_white_button(49f6e7a06ebc5aa8).();
1179 break;
1180 case MatchRequestcxx . . $ MatchRequest#::NIGIRIcxx . . $ MatchRequest#NIGIRI.:
1181 uicxx . . $ GameDialog#ui..play_nigiri_buttoncxx . . $ Ui_GameDialog#play_nigiri_button.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(true);
1182 if(mr->color_requestcxx . . $ MatchRequest#color_request. != current_match_requestcxx . . $ GameDialog#current_match_request.->color_requestcxx . . $ MatchRequest#color_request.)
1183 uicxx . . $ GameDialog#ui..play_nigiri_buttoncxx . . $ Ui_GameDialog#play_nigiri_button.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1184 slot_play_nigiri_buttoncxx . . $ GameDialog#slot_play_nigiri_button(49f6e7a06ebc5aa8).();
1185 break;
1186 }
1187
1188 if(mr->komicxx . . $ MatchRequest#komi. != current_match_requestcxx . . $ GameDialog#current_match_request.->komicxx . . $ MatchRequest#komi.)
1189 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1190 uicxx . . $ GameDialog#ui..komiSpincxx . . $ Ui_GameDialog#komiSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).((int)mr->komicxx . . $ MatchRequest#komi.);
1191
1192
1193 if(mr->board_sizecxx . . $ MatchRequest#board_size. != current_match_requestcxx . . $ GameDialog#current_match_request.->board_sizecxx . . $ MatchRequest#board_size.)
1194 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1195 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->board_sizecxx . . $ MatchRequest#board_size.);
1196
1197 if(mr->handicapcxx . . $ MatchRequest#handicap. != current_match_requestcxx . . $ GameDialog#current_match_request.->handicapcxx . . $ MatchRequest#handicap.)
1198 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1199 uicxx . . $ GameDialog#ui..handicapSpincxx . . $ Ui_GameDialog#handicapSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->handicapcxx . . $ MatchRequest#handicap.);
1200
1201 if (/*mr->nmatch || */mr->timeSystemcxx . . $ MatchRequest#timeSystem. == byoyomicxx . . $ byoyomi.)
1202 {
1203 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("nmatch");
1204 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("%d %d %d", mr->maintimecxx . . $ MatchRequest#maintime., mr->periodtimecxx . . $ MatchRequest#periodtime., mr->stones_periodscxx . . $ MatchRequest#stones_periods.);
1205 //specific behavior here : IGS nmatch not totally supported
1206 // disputes are hardly supported
1207 set_is_nmatchcxx . . $ GameDialog#set_is_nmatch(b45ddcbc8423892c).(true); //FIXME, change to is BY setting
1208 //mr->nmatch = true;
1209 if(mr->maintimecxx . . $ MatchRequest#maintime. != current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime.)
1210 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1211 uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(QTimecxx . . $ QTime#QTime(748afa4755bc9595).(mr->maintimecxx . . $ MatchRequest#maintime./3600, (mr->maintimecxx . . $ MatchRequest#maintime. % 3600)/60, mr->maintimecxx . . $ MatchRequest#maintime.%60));
1212
1213 if(mr->periodtimecxx . . $ MatchRequest#periodtime. != current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime.)
1214 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1215 uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, mr->periodtimecxx . . $ MatchRequest#periodtime./60, mr->periodtimecxx . . $ MatchRequest#periodtime.%60));
1216
1217 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setRangecxx . . $ QSpinBox#setRange(3e454b8ccf442868).(0,99);
1218 if(mr->stones_periodscxx . . $ MatchRequest#stones_periods. != current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods.)
1219 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1220 uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->stones_periodscxx . . $ MatchRequest#stones_periods.);
1221
1222 //ui.BY_label->setText(tr(" Byo Time : (") + mr->stones_periods+ tr(" stones_periods)"));
1223 // necessary? these enables/disables?
1224 //ui.handicapSpin->setEnabled(true);
1225 //ui.play_nigiri_button->setEnabled(true);
1226 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setCurrentIndexcxx . . $ QTabWidget#setCurrentIndex(d4f767463ce0a6b3).(1);
1227 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. != byoyomicxx . . $ byoyomi.)
1228 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1229 if(destroy_other_timetabs && uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->countcxx . . $ QTabWidget#count(455f465bc33b4cdf).() > 1)
1230 {
1231 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(0, false);
1232 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(2, false);
1233 }
1234 }
1235 else if (mr->timeSystemcxx . . $ MatchRequest#timeSystem. == tvasiacxx . . $ tvasia.)
1236 {
1237 /* As I understand it, tv asia time is just
1238 * byo yomi with a maintime in seconds... if I'm wrong, if its
1239 * something else... and I really need to check this in an
1240 * actual ORO on ORO game... */
1241 if(mr->maintimecxx . . $ MatchRequest#maintime. != current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime.)
1242 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1243
1244 uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, mr->maintimecxx . . $ MatchRequest#maintime./60, mr->maintimecxx . . $ MatchRequest#maintime.%60));
1245
1246 if(mr->periodtimecxx . . $ MatchRequest#periodtime. != current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime.)
1247 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1248 uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, mr->periodtimecxx . . $ MatchRequest#periodtime./60, mr->periodtimecxx . . $ MatchRequest#periodtime.%60));
1249
1250 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setRangecxx . . $ QSpinBox#setRange(3e454b8ccf442868).(0,99);
1251 if(mr->stones_periodscxx . . $ MatchRequest#stones_periods. != current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods.)
1252 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1253 uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->stones_periodscxx . . $ MatchRequest#stones_periods.);
1254
1255 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setCurrentIndexcxx . . $ QTabWidget#setCurrentIndex(d4f767463ce0a6b3).(2);
1256 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. != tvasiacxx . . $ tvasia.)
1257 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1258 if(destroy_other_timetabs && uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->countcxx . . $ QTabWidget#count(455f465bc33b4cdf).() > 1)
1259 {
1260 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(0, false);
1261 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(1, false);
1262 }
1263 }
1264 else if(/* !mr->nmatch || */mr->timeSystemcxx . . $ MatchRequest#timeSystem. == canadiancxx . . $ canadian.)
1265 {
1266 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("no nmatch");
1267 set_is_nmatchcxx . . $ GameDialog#set_is_nmatch(b45ddcbc8423892c).(false);
1268
1269 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(qtimeFromSecondscxx . . $ GameDialog#qtimeFromSeconds(bc1d3073fb5de629).(mr->maintimecxx . . $ MatchRequest#maintime.));
1270 if(mr->maintimecxx . . $ MatchRequest#maintime. != current_match_requestcxx . . $ GameDialog#current_match_request.->maintimecxx . . $ MatchRequest#maintime.)
1271 uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1272
1273 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setTimecxx . . $ QDateTimeEdit#setTime(49dbfc5ca47449c).(qtimeFromSecondscxx . . $ GameDialog#qtimeFromSeconds(bc1d3073fb5de629).(mr->periodtimecxx . . $ MatchRequest#periodtime.));
1274 if(mr->periodtimecxx . . $ MatchRequest#periodtime. != current_match_requestcxx . . $ GameDialog#current_match_request.->periodtimecxx . . $ MatchRequest#periodtime.)
1275 uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1276
1277 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->stones_periodscxx . . $ MatchRequest#stones_periods.);
1278 if(mr->stones_periodscxx . . $ MatchRequest#stones_periods. != current_match_requestcxx . . $ GameDialog#current_match_request.->stones_periodscxx . . $ MatchRequest#stones_periods.)
1279 uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1280
1281 // necessary? these enables/disables?
1282 //ui.handicapSpin->setEnabled(false);
1283 //ui.play_nigiri_button->setEnabled(false);
1284
1285 if(mr->board_sizecxx . . $ MatchRequest#board_size. != current_match_requestcxx . . $ GameDialog#current_match_request.->board_sizecxx . . $ MatchRequest#board_size.)
1286 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1287 uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->setValuecxx . . $ QSpinBox#setValue(d4f767463ce0a6b3).(mr->board_sizecxx . . $ MatchRequest#board_size.);
1288
1289 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setCurrentIndexcxx . . $ QTabWidget#setCurrentIndex(d4f767463ce0a6b3).(0);
1290 if(current_match_requestcxx . . $ GameDialog#current_match_request.->timeSystemcxx . . $ MatchRequest#timeSystem. != canadiancxx . . $ canadian.)
1291 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setPalettecxx . . $ QWidget#setPalette(f826ed73d5553cd5).(p);
1292 if(destroy_other_timetabs && uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->countcxx . . $ QTabWidget#count(455f465bc33b4cdf).() > 1)
1293 {
1294 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(1, false);
1295 uicxx . . $ GameDialog#ui..timeTabcxx . . $ Ui_GameDialog#timeTab.->setTabEnabledcxx . . $ QTabWidget#setTabEnabled(918ebd27a9ddbad3).(2, false);
1296 }
1297 }
1298
1299
1300 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("set-up accept");
1301 if(this_is_offer)
1302 {
1303 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(false);
1304 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
1305 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Offer"));
1306 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
1307 }
1308 else
1309 {
1310 uicxx . . $ GameDialog#ui..buttonDeclinecxx . . $ Ui_GameDialog#buttonDecline.->setEnabledcxx . . $ QWidget#setEnabled(b45ddcbc8423892c).(true);
1311 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(false);
1312 uicxx . . $ GameDialog#ui..buttonOffercxx . . $ Ui_GameDialog#buttonOffer.->setTextcxx . . $ QAbstractButton#setText(3520e46b33348bf6).(trcxx . . $ GameDialog#tr(75d9f1c324b4579d).("Accept"));
1313 uicxx . . $ GameDialog#ui..buttonCancelcxx . . $ Ui_GameDialog#buttonCancel.->setDisabledcxx . . $ QWidget#setDisabled(b45ddcbc8423892c).(true);
1314 }
1315
1316 showcxx . . $ QWidget#show(49f6e7a06ebc5aa8).();
1317 // dlg->setWindowState(Qt::WindowActive);
1318 raisecxx . . $ QWidget#raise(49f6e7a06ebc5aa8).();
1319
1320 if(!this_is_offer)
1321 gameSoundcxx . . $ GameDialog#gameSound.->playcxx . . $ Sound#play(49f6e7a06ebc5aa8).();
1322 // store this as the new offer
1323 *current_match_requestcxx . . $ GameDialog#current_match_request. =cxx . . $ MatchRequest#`operator=`(192481a576b2c65a). *mr;
1324 clearChangedFlagscxx . . $ GameDialog#clearChangedFlags(49f6e7a06ebc5aa8).();
1325 }
1326
1327 void GameDialogcxx . . $ GameDialog#::save_to_preferencescxx . . $ GameDialog#save_to_preferences(49f6e7a06ebc5aa8).(void)
1328 {
1329 preferencescxx . . $ preferences..default_sizecxx . . $ _preferences#default_size. = uicxx . . $ GameDialog#ui..boardSizeSpincxx . . $ Ui_GameDialog#boardSizeSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
1330 //preferences.default_komi = ui.komiSpin->value();
1331
1332 preferencescxx . . $ preferences..default_stonesmaintimecxx . . $ _preferences#default_stonesmaintime. = timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(uicxx . . $ GameDialog#ui..timeSpincxx . . $ Ui_GameDialog#timeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).());
1333 preferencescxx . . $ preferences..default_stonestimecxx . . $ _preferences#default_stonestime. = (uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + uicxx . . $ GameDialog#ui..stonesTimeSpincxx . . $ Ui_GameDialog#stonesTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
1334 preferencescxx . . $ preferences..default_stonescxx . . $ _preferences#default_stones. = uicxx . . $ GameDialog#ui..stonesSpincxx . . $ Ui_GameDialog#stonesSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
1335 preferencescxx . . $ preferences..default_byomaintimecxx . . $ _preferences#default_byomaintime. = (uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + uicxx . . $ GameDialog#ui..BYTimeSpincxx . . $ Ui_GameDialog#BYTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
1336 preferencescxx . . $ preferences..default_byoperiodtimecxx . . $ _preferences#default_byoperiodtime. = (uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + uicxx . . $ GameDialog#ui..BYPeriodTimeSpincxx . . $ Ui_GameDialog#BYPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
1337 preferencescxx . . $ preferences..default_byoperiodscxx . . $ _preferences#default_byoperiods. = uicxx . . $ GameDialog#ui..BYPeriodsSpincxx . . $ Ui_GameDialog#BYPeriodsSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
1338 preferencescxx . . $ preferences..default_asiamaintimecxx . . $ _preferences#default_asiamaintime. = (uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + uicxx . . $ GameDialog#ui..ASIATimeSpincxx . . $ Ui_GameDialog#ASIATimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
1339 preferencescxx . . $ preferences..default_asiaperiodtimecxx . . $ _preferences#default_asiaperiodtime. = (uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + uicxx . . $ GameDialog#ui..ASIAPeriodTimeSpincxx . . $ Ui_GameDialog#ASIAPeriodTimeSpin.->timecxx . . $ QDateTimeEdit#time(8a5b0eee758a2eda).().secondcxx . . $ QTime#second(455f465bc33b4cdf).();
1340 preferencescxx . . $ preferences..default_asiaperiodscxx . . $ _preferences#default_asiaperiods. = uicxx . . $ GameDialog#ui..ASIAPeriodsSpincxx . . $ Ui_GameDialog#ASIAPeriodsSpin.->valuecxx . . $ QSpinBox#value(455f465bc33b4cdf).();
1341 }
1342
1343
1344 MatchRequestcxx . . $ MatchRequest# * GameDialogcxx . . $ GameDialog#::getMatchRequestcxx . . $ GameDialog#getMatchRequest(bd616a0a6add31e0).(void)
1345 {
1346 return current_match_requestcxx . . $ GameDialog#current_match_request.;
1347 }
1348
1349 QTimecxx . . $ QTime# GameDialogcxx . . $ GameDialog#::qtimeFromSecondscxx . . $ GameDialog#qtimeFromSeconds(bc1d3073fb5de629).(int seconds)
1350 {
1351 if(seconds == 0)
1352 return QTimecxx . . $ QTime#QTime(748afa4755bc9595).(0, 0, 0);
1353 int minutes = seconds / 60;
1354 int hours;
1355 seconds %= 60;
1356 if(minutes == 0)
1357 hours = 0;
1358 else
1359 {
1360 hours = minutes / 60;
1361 minutes %= 60;
1362 }
1363 return QTimecxx . . $ QTime#QTime(748afa4755bc9595).(hours, minutes, seconds);
1364 }
1365
1366 unsigned int GameDialogcxx . . $ GameDialog#::timeToSecondscxx . . $ GameDialog#timeToSeconds(9d92bb507a34628c).(QStringcxx . . $ QString# time)
1367 {
1368 QRegExpcxx . . $ QRegExp# re = QRegExpcxx . . $ QRegExp#QRegExp(31e086911ff70bd0).("([0-9]{1,3}):([0-9]{1,2})"cxx . . $ QString#QString(85c52e162fed56f9).);
1369 int min, sec;
1370
1371 if(re.indexIncxx . . $ QRegExp#indexIn(46f502bdfc4aeb33).(time) >= 0)
1372 {
1373 min = re.capcxx . . $ QRegExp#cap(ce915ed341d4a7f0).(1).toIntcxx . . $ QString#toInt(d7972accae11ee1f).();
1374 sec = re.capcxx . . $ QRegExp#cap(ce915ed341d4a7f0).(2).toIntcxx . . $ QString#toInt(d7972accae11ee1f).();
1375 }
1376 else
1377 {
1378 qDebugcxx . . $ `<external>/10450329605257866924/qlogging.h:164:9`!("Bad time string");
1379 return 0xffff;
1380 }
1381
1382 return (60 * min) + sec;
1383 }
1384
1385 unsigned int GameDialogcxx . . $ GameDialog#::timeToSecondscxx . . $ GameDialog#timeToSeconds(eec77867f105fb76).(const QTimecxx . . $ QTime# & t)
1386 {
1387 return ((t.hourcxx . . $ QTime#hour(455f465bc33b4cdf).() * 3600) + (t.minutecxx . . $ QTime#minute(455f465bc33b4cdf).() * 60) + t.secondcxx . . $ QTime#second(455f465bc33b4cdf).());
1388 }
1389
1390 //we just assume that white has the higher rank
1391 /* We're having this return 1 handicap if there's a one stone
1392 * difference, but this only works because this is only called
1393 * from the one place... then we'll use the GDF_HANDICAP1 flag
1394 * to determine if that's set */
1395 bool GameDialogcxx . . $ GameDialog#::getProperKomiHandicapcxx . . $ GameDialog#getProperKomiHandicap(a24a5210c7470c29).(QStringcxx . . $ QString# rankA, QStringcxx . . $ QString# rankB, float * komi, unsigned int * handicap)
1396 {
1397 /* Check for k, d, or p (as d), calc difference, */
1398 QStringcxx . . $ QString# buffer = rankAcxx . . $ QString#QString(132dd6869045752b).;
1399 buffer.replacecxx . . $ QString#replace(612862c8abff0ba5).(QRegExpcxx . . $ QRegExp#QRegExp(31e086911ff70bd0).("[pdk+?]"cxx . . $ QString#QString(85c52e162fed56f9).), ""cxx . . $ QString#QString(85c52e162fed56f9).);
1400 int ordinalA = buffer.toIntcxx . . $ QString#toInt(d7972accae11ee1f).();
1401 buffer =cxx . . $ QString#`operator=`(b79fde0b0ce9b948). rankB;
1402 buffer.replacecxx . . $ QString#replace(612862c8abff0ba5).(QRegExpcxx . . $ QRegExp#QRegExp(31e086911ff70bd0).("[pdk+?]"cxx . . $ QString#QString(85c52e162fed56f9).), ""cxx . . $ QString#QString(85c52e162fed56f9).);
1403 int ordinalB = buffer.toIntcxx . . $ QString#toInt(d7972accae11ee1f).();
1404 int difference;
1405 bool A_lowerthan_B = false;
1406
1407 if((rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("k"cxx . . $ QString#QString(85c52e162fed56f9).) && (rankB.containscxx . . $ QString#contains(8cce4688c16f48f3).("d"cxx . . $ QString#QString(85c52e162fed56f9).) || rankB.containscxx . . $ QString#contains(8cce4688c16f48f3).("p"cxx . . $ QString#QString(85c52e162fed56f9).)))
1408 || (rankB.containscxx . . $ QString#contains(8cce4688c16f48f3).("k"cxx . . $ QString#QString(85c52e162fed56f9).) && (rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("d"cxx . . $ QString#QString(85c52e162fed56f9).) || rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("p"cxx . . $ QString#QString(85c52e162fed56f9).))))
1409 {
1410 difference = ordinalB + ordinalA - 1;
1411 *komi = 0.0;
1412 if(difference == 1)
1413 *handicap = 1;
1414 else if(difference > 9)
1415 *handicap = 9;
1416 else
1417 *handicap = difference;
1418 if(rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("k"cxx . . $ QString#QString(85c52e162fed56f9).))
1419 A_lowerthan_B = true;
1420 else
1421 A_lowerthan_B = false;
1422
1423 }
1424 else
1425 {
1426 if(ordinalA == ordinalB)
1427 {
1428 *komi = preferencescxx . . $ preferences..default_komicxx . . $ _preferences#default_komi.;
1429 *handicap = 0;
1430 }
1431 else
1432 {
1433 difference = abs(ordinalA - ordinalB);
1434 *komi = 0.0;
1435 if(difference == 1)
1436 *handicap = 1;
1437 else if(difference > 9)
1438 *handicap = 9;
1439 else
1440 *handicap = difference;
1441 if(ordinalA > ordinalB && rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("k"cxx . . $ QString#QString(85c52e162fed56f9).))
1442 A_lowerthan_B = true;
1443 else if(ordinalA < ordinalB && rankA.containscxx . . $ QString#contains(8cce4688c16f48f3).("k"cxx . . $ QString#QString(85c52e162fed56f9).))
1444 A_lowerthan_B = false;
1445 else if(ordinalA > ordinalB)
1446 A_lowerthan_B = false;
1447 else if(ordinalA < ordinalB)
1448 A_lowerthan_B = true;
1449 }
1450 }
1451 return A_lowerthan_B;
1452 }