| 1 | #cxx . . $ `<file>/src/PaletteDialog.cpp`/include <QSignalMapper> |
| 2 | #include <QPushButton> |
| 3 | #include <QGridLayout> |
| 4 | #include <QPainter> |
| 5 | #include "PaletteDialog.h"cxx . . $ `<file>/src/PaletteDialog.h`/ |
| 6 | #include "Convert.h"cxx . . $ `<file>/src/Convert.h`/ |
| 7 | #include "VDPDataStore.h"cxx . . $ `<file>/src/VDPDataStore.h`/ |
| 8 | #include "ranges.h"cxx . . $ `<file>/src/ranges.h`/ |
| 9 | |
| 10 | |
| 11 | PalettePatchcxx . . $ PalettePatch#::PalettePatchcxx . . $ PalettePatch#PalettePatch(156e3b1c1bd4a3d5).(QWidgetcxx . . $ QWidget#* parent, int palNr) |
| 12 | : QPushButtoncxx . . $ QPushButton#(parent), msxPalNrcxx . . $ PalettePatch#msxPalNr.(palNr) |
| 13 | { |
| 14 | } |
| 15 | |
| 16 | //void PalettePatch::setColor(QRgb c) |
| 17 | //{ |
| 18 | // myColor = c; |
| 19 | // update(); |
| 20 | //} |
| 21 | |
| 22 | void PalettePatchcxx . . $ PalettePatch#::updatePaletteChangedcxx . . $ PalettePatch#updatePaletteChanged(28caea9380bfac8a).(const uint8_tcxx . . $ uint8_t#* pal) |
| 23 | { |
| 24 | int r = (pal[2 * msxPalNrcxx . . $ PalettePatch#msxPalNr. + 0] & 0xf0) >> 4; |
| 25 | int b = (pal[2 * msxPalNrcxx . . $ PalettePatch#msxPalNr. + 0] & 0x0f); |
| 26 | int g = (pal[2 * msxPalNrcxx . . $ PalettePatch#msxPalNr. + 1] & 0x0f); |
| 27 | auto scale = [](int x) { return (x >> 1) | (x << 2) | (x << 5); }; |
| 28 | myColorcxx . . $ PalettePatch#myColor. = qRgbcxx . . $ qRgb(530956271a9518a5).(scale(cxx . . $ PalettePatch#updatePaletteChanged(28caea9380bfac8a).$anonymous_type_0#`operator()`(7ccb52b1bfe01045).r), scale(cxx . . $ PalettePatch#updatePaletteChanged(28caea9380bfac8a).$anonymous_type_0#`operator()`(7ccb52b1bfe01045).g), scale(cxx . . $ PalettePatch#updatePaletteChanged(28caea9380bfac8a).$anonymous_type_0#`operator()`(7ccb52b1bfe01045).b)); |
| 29 | setSizePolicycxx . . $ QWidget#setSizePolicy(41340f53ecd443dd).(QSizePolicycxx . . $ QSizePolicy#QSizePolicy(dc90913e2b9d0ddb).(QSizePolicycxx . . $ QSizePolicy#::Expandingcxx . . $ QSizePolicy#Expanding., QSizePolicycxx . . $ QSizePolicy#::Expandingcxx . . $ QSizePolicy#Expanding.)); |
| 30 | updatecxx . . $ QWidget#update(49f6e7a06ebc5aa8).(); |
| 31 | //printf("PalettePatch::updatePaletteChanged %i\n", msxPalNr); |
| 32 | } |
| 33 | |
| 34 | void PalettePatchcxx . . $ PalettePatch#::setHighlightTestcxx . . $ PalettePatch#setHighlightTest(d4f767463ce0a6b3).(int colorNr) |
| 35 | { |
| 36 | bool s = colorNr == msxPalNrcxx . . $ PalettePatch#msxPalNr.; |
| 37 | if (isSelectedcxx . . $ PalettePatch#isSelected. == s) return; |
| 38 | isSelectedcxx . . $ PalettePatch#isSelected. = s; |
| 39 | updatecxx . . $ QWidget#update(49f6e7a06ebc5aa8).(); |
| 40 | } |
| 41 | |
| 42 | void PalettePatchcxx . . $ PalettePatch#::paintEventcxx . . $ PalettePatch#paintEvent(f239c9e85d61a220).(QPaintEventcxx . . $ QPaintEvent#* /*event*/) |
| 43 | { |
| 44 | QPaintercxx . . $ QPainter# paintercxx . . $ QPainter#QPainter(dd2eedc069b0ab5f).(this); |
| 45 | painter.setPencxx . . $ QPainter#setPen(129a55e114526ad3).(isSelectedcxx . . $ PalettePatch#isSelected. ? Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::whitecxx . . $ Qt/white. : QColorcxx . . $ QColor#QColor(6bab9b75950d6f3).(myColorcxx . . $ PalettePatch#myColor.)); |
| 46 | painter.setBrushcxx . . $ QPainter#setBrush(ffc9f5d0bda78261).(QBrushcxx . . $ QBrush#QBrush(b50947b0752ea6ac).(myColorcxx . . $ QColor#QColor(6bab9b75950d6f3).)); |
| 47 | painter.drawRectcxx . . $ QPainter#drawRect(748afa4755bc9595).(0, 0, this->widthcxx . . $ QWidget#width(455f465bc33b4cdf).() - 1, this->heightcxx . . $ QWidget#height(455f465bc33b4cdf).() - 1); |
| 48 | } |
| 49 | |
| 50 | PaletteDialogcxx . . $ PaletteDialog#::PaletteDialogcxx . . $ PaletteDialog#PaletteDialog(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget#* parent) |
| 51 | : QDialogcxx . . $ QDialog#QDialog(872e7b0c281abd8d).(parent), uicxx . . $ PaletteDialog#ui.(stdcxx . . $ std/::make_uniquecxx . . $ std/make_unique(5cd499e8540a10bb).<Uicxx . . $ Ui/::PaletteDialogcxx . . $ Ui/PaletteDialog#>()) |
| 52 | { |
| 53 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).setupUicxx . . $ Ui_PaletteDialog#setupUi(d194de0c0f68c28b).(this); |
| 54 | connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Rcxx . . $ Ui_PaletteDialog#horizontalSlider_R., &QSlidercxx . . $ QSlider#::valueChangedcxx . . $ QAbstractSlider#valueChanged(d4f767463ce0a6b3)., this, &PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_R_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_R_valueChanged(d4f767463ce0a6b3).); |
| 55 | connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Gcxx . . $ Ui_PaletteDialog#horizontalSlider_G., &QSlidercxx . . $ QSlider#::valueChangedcxx . . $ QAbstractSlider#valueChanged(d4f767463ce0a6b3)., this, &PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_G_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_G_valueChanged(d4f767463ce0a6b3).); |
| 56 | connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Bcxx . . $ Ui_PaletteDialog#horizontalSlider_B., &QSlidercxx . . $ QSlider#::valueChangedcxx . . $ QAbstractSlider#valueChanged(d4f767463ce0a6b3)., this, &PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_B_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_B_valueChanged(d4f767463ce0a6b3).); |
| 57 | connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).buttonBoxcxx . . $ Ui_PaletteDialog#buttonBox., &QDialogButtonBoxcxx . . $ QDialogButtonBox#::clickedcxx . . $ QDialogButtonBox#clicked(6f406f547f7da55f)., this, &PaletteDialogcxx . . $ PaletteDialog#::on_buttonBox_clickedcxx . . $ PaletteDialog#on_buttonBox_clicked(6f406f547f7da55f).); |
| 58 | connectcxx . . $ QObject#connect(835f87066c895669).(uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).cb_autosynccxx . . $ Ui_PaletteDialog#cb_autosync., &QCheckBoxcxx . . $ QCheckBox#::stateChangedcxx . . $ QCheckBox#stateChanged(d4f767463ce0a6b3)., this, &PaletteDialogcxx . . $ PaletteDialog#::on_cb_autosync_stateChangedcxx . . $ PaletteDialog#on_cb_autosync_stateChanged(d4f767463ce0a6b3).); |
| 59 | |
| 60 | const QFontcxx . . $ QFont# fixedFont = QFontDatabasecxx . . $ QFontDatabase#::systemFontcxx . . $ QFontDatabase#systemFont(2e2fed7ba119aa62).(QFontDatabasecxx . . $ QFontDatabase#::FixedFontcxx . . $ QFontDatabase#FixedFont.); |
| 61 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).plainTextEditcxx . . $ Ui_PaletteDialog#plainTextEdit.->setFontcxx . . $ QWidget#setFont(d0a4bd0c8524b912).(fixedFont); |
| 62 | |
| 63 | setWindowTitlecxx . . $ QWidget#setWindowTitle(3520e46b33348bf6).("Palette editor"cxx . . $ QString#QString(85c52e162fed56f9).); |
| 64 | rangescxx . . $ ranges/::fillcxx . . $ ranges/fill(af49599c1c6f79df).(myPalcxx . . $ PaletteDialog#myPal., 0); |
| 65 | rangescxx . . $ ranges/::fillcxx . . $ ranges/fill(af49599c1c6f79df).(myOriginalPalcxx . . $ PaletteDialog#myOriginalPal., 0); |
| 66 | // add colors to colorframe |
| 67 | |
| 68 | signalMappercxx . . $ PaletteDialog#signalMapper. = new QSignalMappercxx . . $ QSignalMapper#(this); |
| 69 | auto* gridLayout = new QGridLayoutcxx . . $ QGridLayout#; |
| 70 | gridLayout->setSpacingcxx . . $ QGridLayout#setSpacing(d4f767463ce0a6b3).(0); |
| 71 | for (int i = 0; i < 16; ++i) { |
| 72 | auto* button = new PalettePatchcxx . . $ PalettePatch#(nullptr, i); |
| 73 | connectcxx . . $ QObject#connect(835f87066c895669).(button, &PalettePatchcxx . . $ PalettePatch#::clickedcxx . . $ QAbstractButton#clicked(b45ddcbc8423892c)., signalMappercxx . . $ PaletteDialog#signalMapper., qOverloadcxx . . $ qOverload.<>(cxx . . $ QNonConstOverload#`operator()`(a8f97e06674de5d1).&QSignalMappercxx . . $ QSignalMapper#::mapcxx . . $ QSignalMapper#map(49f6e7a06ebc5aa8).)); |
| 74 | signalMappercxx . . $ PaletteDialog#signalMapper.->setMappingcxx . . $ QSignalMapper#setMapping(3f47e595a91bc133).(button, i); |
| 75 | gridLayout->addWidgetcxx . . $ QGridLayout#addWidget(17d1465fab362e2d).(button, i / 8, i % 8); |
| 76 | connectcxx . . $ QObject#connect(835f87066c895669).(this, &PaletteDialogcxx . . $ PaletteDialog#::paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7)., |
| 77 | button, &PalettePatchcxx . . $ PalettePatch#::updatePaletteChangedcxx . . $ PalettePatch#updatePaletteChanged(28caea9380bfac8a).); |
| 78 | connectcxx . . $ QObject#connect(835f87066c895669).(signalMappercxx . . $ PaletteDialog#signalMapper., &QSignalMappercxx . . $ QSignalMapper#::mappedIntcxx . . $ QSignalMapper#mappedInt(d4f767463ce0a6b3)., |
| 79 | button, &PalettePatchcxx . . $ PalettePatch#::setHighlightTestcxx . . $ PalettePatch#setHighlightTest(d4f767463ce0a6b3).); |
| 80 | } |
| 81 | |
| 82 | connectcxx . . $ QObject#connect(835f87066c895669).(signalMappercxx . . $ PaletteDialog#signalMapper., &QSignalMappercxx . . $ QSignalMapper#::mappedIntcxx . . $ QSignalMapper#mappedInt(d4f767463ce0a6b3)., |
| 83 | this, &PaletteDialogcxx . . $ PaletteDialog#::colorSelectedcxx . . $ PaletteDialog#colorSelected(d4f767463ce0a6b3).); |
| 84 | |
| 85 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).colorsframecxx . . $ Ui_PaletteDialog#colorsframe.->setLayoutcxx . . $ QWidget#setLayout(23396b1058755fec).(gridLayout); |
| 86 | connectcxx . . $ QObject#connect(835f87066c895669).(this, &PaletteDialogcxx . . $ PaletteDialog#::paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7)., |
| 87 | this, &PaletteDialogcxx . . $ PaletteDialog#::updateTextcxx . . $ PaletteDialog#updateText(49f6e7a06ebc5aa8).); |
| 88 | } |
| 89 | |
| 90 | void PaletteDialogcxx . . $ PaletteDialog#::updateTextcxx . . $ PaletteDialog#updateText(49f6e7a06ebc5aa8).() |
| 91 | { |
| 92 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).plainTextEditcxx . . $ Ui_PaletteDialog#plainTextEdit.->clearcxx . . $ QPlainTextEdit#clear(49f6e7a06ebc5aa8).(); |
| 93 | for (int i = 0; i < 4; ++i) { |
| 94 | QStringcxx . . $ QString# txtcxx . . $ QString#QString(85c52e162fed56f9).(" db "); |
| 95 | for (int j = 0; j < 4; ++j) { |
| 96 | txt.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1,%2 ") |
| 97 | .argcxx . . $ QString#arg(bc823072288cbbb5).(hexValuecxx . . $ hexValue(f4fd9db251ca774b).(myPalcxx . . $ PaletteDialog#myPal.[2 * (j + 4 * i) + 0], 2)) |
| 98 | .argcxx . . $ QString#arg(bc823072288cbbb5).(hexValuecxx . . $ hexValue(f4fd9db251ca774b).(myPalcxx . . $ PaletteDialog#myPal.[2 * (j + 4 * i) + 1], 2))); |
| 99 | if (j < 3) txt.appendcxx . . $ QString#append(3a2ffbdf8ecc25e2).(','cxx . . $ QChar#QChar(f349c77f591a7878).); |
| 100 | } |
| 101 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).plainTextEditcxx . . $ Ui_PaletteDialog#plainTextEdit.->appendPlainTextcxx . . $ QPlainTextEdit#appendPlainText(3520e46b33348bf6).(txt); |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | void PaletteDialogcxx . . $ PaletteDialog#::restoreOpeningsPalettecxx . . $ PaletteDialog#restoreOpeningsPalette(49f6e7a06ebc5aa8).() |
| 106 | { |
| 107 | memcpy(myPalcxx . . $ PaletteDialog#myPal., myOriginalPalcxx . . $ PaletteDialog#myOriginalPal., sizeof(myPalcxx . . $ PaletteDialog#myPal.)); |
| 108 | emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7).(myPalcxx . . $ PaletteDialog#myPal.); // Resets the PalettePatches |
| 109 | colorSelectedcxx . . $ PaletteDialog#colorSelected(d4f767463ce0a6b3).(currentColorcxx . . $ PaletteDialog#currentColor.); // Resets the sliders |
| 110 | if (autoSynccxx . . $ PaletteDialog#autoSync.) { |
| 111 | syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).(); |
| 112 | } |
| 113 | } |
| 114 | |
| 115 | void PaletteDialogcxx . . $ PaletteDialog#::colorSelectedcxx . . $ PaletteDialog#colorSelected(d4f767463ce0a6b3).(int colorNumber) |
| 116 | { |
| 117 | currentColorcxx . . $ PaletteDialog#currentColor. = colorNumber; |
| 118 | int r = (myPalcxx . . $ PaletteDialog#myPal.[2 * currentColorcxx . . $ PaletteDialog#currentColor. + 0] & 0xf0) >> 4; |
| 119 | int b = (myPalcxx . . $ PaletteDialog#myPal.[2 * currentColorcxx . . $ PaletteDialog#currentColor. + 0] & 0x0f); |
| 120 | int g = (myPalcxx . . $ PaletteDialog#myPal.[2 * currentColorcxx . . $ PaletteDialog#currentColor. + 1] & 0x0f); |
| 121 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Rcxx . . $ Ui_PaletteDialog#horizontalSlider_R.->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(r); |
| 122 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Gcxx . . $ Ui_PaletteDialog#horizontalSlider_G.->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(g); |
| 123 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Bcxx . . $ Ui_PaletteDialog#horizontalSlider_B.->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(b); |
| 124 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).label_colornrcxx . . $ Ui_PaletteDialog#label_colornr.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("Color %1").argcxx . . $ QString#arg(64ab2ed17cc11715).(colorNumber)); |
| 125 | } |
| 126 | |
| 127 | void PaletteDialogcxx . . $ PaletteDialog#::setPalettecxx . . $ PaletteDialog#setPalette(f25546b61a629de7).(uint8_tcxx . . $ uint8_t#* pal) |
| 128 | { |
| 129 | sourcePalcxx . . $ PaletteDialog#sourcePal. = pal; |
| 130 | memcpy(myOriginalPalcxx . . $ PaletteDialog#myOriginalPal., pal, sizeof(myOriginalPalcxx . . $ PaletteDialog#myOriginalPal.)); |
| 131 | memcpy(myPalcxx . . $ PaletteDialog#myPal., pal, sizeof(myPalcxx . . $ PaletteDialog#myPal.)); |
| 132 | emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7).(myPalcxx . . $ PaletteDialog#myPal.); |
| 133 | } |
| 134 | |
| 135 | uint8_tcxx . . $ uint8_t#* PaletteDialogcxx . . $ PaletteDialog#::getPalettecxx . . $ PaletteDialog#getPalette(37d8967d10cb1e7b).() |
| 136 | { |
| 137 | return myPalcxx . . $ PaletteDialog#myPal.; |
| 138 | } |
| 139 | |
| 140 | //void PaletteDialog::decodepalette() |
| 141 | //{ |
| 142 | // for (int i = 0; i < 16; ++i) { |
| 143 | // int r = (myPal[2 * i + 0] & 0xf0) >> 4; |
| 144 | // int b = (myPal[2 * i + 0] & 0x0f); |
| 145 | // int g = (myPal[2 * i + 1] & 0x0f); |
| 146 | // |
| 147 | // auto scale = [](int x) { return (x >> 1) | (x << 2) | (x << 5); }; |
| 148 | // msxPalette[i] = qRgb(scale(r), scale(g), scale(b)); |
| 149 | // |
| 150 | // QGridLayout* l = dynamic_cast<QGridLayout*>(ui->colorsframe->layout()); |
| 151 | // dynamic_cast<QPushButton*>(l->itemAtPosition(i % 8, i / 8)->widget())->setText(QString("%1(%2%3%4)").arg(i).arg(r).arg(g).arg(b)); |
| 152 | // } |
| 153 | //} |
| 154 | |
| 155 | void PaletteDialogcxx . . $ PaletteDialog#::combineRGBcxx . . $ PaletteDialog#combineRGB(49f6e7a06ebc5aa8).() |
| 156 | { |
| 157 | int r = uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Rcxx . . $ Ui_PaletteDialog#horizontalSlider_R.->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).(); |
| 158 | int g = uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Gcxx . . $ Ui_PaletteDialog#horizontalSlider_G.->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).(); |
| 159 | int b = uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).horizontalSlider_Bcxx . . $ Ui_PaletteDialog#horizontalSlider_B.->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).(); |
| 160 | myPalcxx . . $ PaletteDialog#myPal.[2 * currentColorcxx . . $ PaletteDialog#currentColor. + 0] = 16 * r + b; |
| 161 | myPalcxx . . $ PaletteDialog#myPal.[2 * currentColorcxx . . $ PaletteDialog#currentColor. + 1] = g; |
| 162 | emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7).(myPalcxx . . $ PaletteDialog#myPal.); |
| 163 | if (autoSynccxx . . $ PaletteDialog#autoSync.) { |
| 164 | syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).(); |
| 165 | } |
| 166 | } |
| 167 | |
| 168 | void PaletteDialogcxx . . $ PaletteDialog#::syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).() |
| 169 | { |
| 170 | memcpy(sourcePalcxx . . $ PaletteDialog#sourcePal., myPalcxx . . $ PaletteDialog#myPal., sizeof(myPalcxx . . $ PaletteDialog#myPal.)); |
| 171 | emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! paletteSyncedcxx . . $ PaletteDialog#paletteSynced(49f6e7a06ebc5aa8).(); |
| 172 | } |
| 173 | |
| 174 | void PaletteDialogcxx . . $ PaletteDialog#::restoreDefaultPalettecxx . . $ PaletteDialog#restoreDefaultPalette(49f6e7a06ebc5aa8).() |
| 175 | { |
| 176 | memcpy(myPalcxx . . $ PaletteDialog#myPal., VDPDataStorecxx . . $ VDPDataStore#::instancecxx . . $ VDPDataStore#instance(6179f7cf4255f5b).().getDefaultPalettePointercxx . . $ VDPDataStore#getDefaultPalettePointer(7eb257f306f79f97).(), 32); |
| 177 | emitcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:97:10`! paletteChangedcxx . . $ PaletteDialog#paletteChanged(f25546b61a629de7).(myPalcxx . . $ PaletteDialog#myPal.); |
| 178 | if (autoSynccxx . . $ PaletteDialog#autoSync.) { |
| 179 | syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).(); |
| 180 | } |
| 181 | } |
| 182 | |
| 183 | void PaletteDialogcxx . . $ PaletteDialog#::setAutoSynccxx . . $ PaletteDialog#setAutoSync(b45ddcbc8423892c).(bool value) |
| 184 | { |
| 185 | if (autoSynccxx . . $ PaletteDialog#autoSync. == value) return; |
| 186 | autoSynccxx . . $ PaletteDialog#autoSync. = value; |
| 187 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).cb_autosynccxx . . $ Ui_PaletteDialog#cb_autosync.->setCheckedcxx . . $ QAbstractButton#setChecked(b45ddcbc8423892c).(value); |
| 188 | } |
| 189 | |
| 190 | void PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_R_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_R_valueChanged(d4f767463ce0a6b3).(int value) |
| 191 | { |
| 192 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).label_Rcxx . . $ Ui_PaletteDialog#label_R.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("R=%1").argcxx . . $ QString#arg(64ab2ed17cc11715).(value)); |
| 193 | combineRGBcxx . . $ PaletteDialog#combineRGB(49f6e7a06ebc5aa8).(); |
| 194 | } |
| 195 | |
| 196 | void PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_G_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_G_valueChanged(d4f767463ce0a6b3).(int value) |
| 197 | { |
| 198 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).label_Gcxx . . $ Ui_PaletteDialog#label_G.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("G=%1").argcxx . . $ QString#arg(64ab2ed17cc11715).(value)); |
| 199 | combineRGBcxx . . $ PaletteDialog#combineRGB(49f6e7a06ebc5aa8).(); |
| 200 | } |
| 201 | |
| 202 | void PaletteDialogcxx . . $ PaletteDialog#::on_horizontalSlider_B_valueChangedcxx . . $ PaletteDialog#on_horizontalSlider_B_valueChanged(d4f767463ce0a6b3).(int value) |
| 203 | { |
| 204 | uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).label_Bcxx . . $ Ui_PaletteDialog#label_B.->setTextcxx . . $ QLabel#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("B=%1").argcxx . . $ QString#arg(64ab2ed17cc11715).(value)); |
| 205 | combineRGBcxx . . $ PaletteDialog#combineRGB(49f6e7a06ebc5aa8).(); |
| 206 | } |
| 207 | |
| 208 | void PaletteDialogcxx . . $ PaletteDialog#::on_buttonBox_clickedcxx . . $ PaletteDialog#on_buttonBox_clicked(6f406f547f7da55f).(QAbstractButtoncxx . . $ QAbstractButton#* button) |
| 209 | { |
| 210 | if (button== uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).buttonBoxcxx . . $ Ui_PaletteDialog#buttonBox.->buttoncxx . . $ QDialogButtonBox#button(3b1c1f83a3cc2105).(QDialogButtonBoxcxx . . $ QDialogButtonBox#::RestoreDefaultscxx . . $ QDialogButtonBox#RestoreDefaults.)) { |
| 211 | restoreDefaultPalettecxx . . $ PaletteDialog#restoreDefaultPalette(49f6e7a06ebc5aa8).(); |
| 212 | } else if (button== uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).buttonBoxcxx . . $ Ui_PaletteDialog#buttonBox.->buttoncxx . . $ QDialogButtonBox#button(3b1c1f83a3cc2105).(QDialogButtonBoxcxx . . $ QDialogButtonBox#::Okcxx . . $ QDialogButtonBox#Ok.)) { |
| 213 | syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).(); |
| 214 | } else if (button== uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).buttonBoxcxx . . $ Ui_PaletteDialog#buttonBox.->buttoncxx . . $ QDialogButtonBox#button(3b1c1f83a3cc2105).(QDialogButtonBoxcxx . . $ QDialogButtonBox#::Resetcxx . . $ QDialogButtonBox#Reset.) || |
| 215 | button== uicxx . . $ PaletteDialog#ui.->cxx . . $ std/unique_ptr#`operator->`(ea7391e9eeeaf20e).buttonBoxcxx . . $ Ui_PaletteDialog#buttonBox.->buttoncxx . . $ QDialogButtonBox#button(3b1c1f83a3cc2105).(QDialogButtonBoxcxx . . $ QDialogButtonBox#::Cancelcxx . . $ QDialogButtonBox#Cancel.)) { |
| 216 | restoreOpeningsPalettecxx . . $ PaletteDialog#restoreOpeningsPalette(49f6e7a06ebc5aa8).(); |
| 217 | } |
| 218 | } |
| 219 | |
| 220 | void PaletteDialogcxx . . $ PaletteDialog#::on_cb_autosync_stateChangedcxx . . $ PaletteDialog#on_cb_autosync_stateChanged(d4f767463ce0a6b3).(int arg1) |
| 221 | { |
| 222 | autoSynccxx . . $ PaletteDialog#autoSync. = arg1 != Qtcxx . . $ Qt/::Uncheckedcxx . . $ Qt/Unchecked.; |
| 223 | if (autoSynccxx . . $ PaletteDialog#autoSync.) { |
| 224 | syncToSourcecxx . . $ PaletteDialog#syncToSource(49f6e7a06ebc5aa8).(); |
| 225 | } |
| 226 | } |