Implement MainRAM management dialog😁 (#1248)

* Implement MainRAM management dialog

* Modify RAMInfoDialog

- use emuThread to avoid a race condition.
- replace RAMUpdateThread to QTimer

Co-Authored-By: RSDuck <RSDuck@users.noreply.github.com>

* Update src/frontend/qt_sdl/RAMInfoDialog.cpp

small typo

Co-authored-by: Rayyan Ansari <68647953+RayyanAnsari@users.noreply.github.com>

* Update src/frontend/qt_sdl/RAMInfoDialog.h

small typo

Co-authored-by: Rayyan Ansari <68647953+RayyanAnsari@users.noreply.github.com>

* typo errors in RAMInfoDialog

Rrevious->Previous

* add new line to the end of the file

Co-authored-by: Rayyan Ansari <rayyan@ansari.sh>

* enable raminfo when cart is inserted

* Modify that only the 'value' item can be edited in RAMinfoDialog

* fix: function name incorrect error

* fix: function name incorrect error2

* fix: wrong way to get ram value

Co-authored-by: RSDuck <RSDuck@users.noreply.github.com>
Co-authored-by: Rayyan Ansari <68647953+RayyanAnsari@users.noreply.github.com>
Co-authored-by: Rayyan Ansari <rayyan@ansari.sh>
This commit is contained in:
2jun0
2022-03-07 06:33:11 +09:00
committed by GitHub
parent 38c8b886ea
commit c66df57256
6 changed files with 714 additions and 0 deletions

View File

@ -0,0 +1,237 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>RAMInfoDialog</class>
<widget class="QDialog" name="RAMInfoDialog">
<property name="enabled">
<bool>true</bool>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>550</width>
<height>411</height>
</rect>
</property>
<property name="minimumSize">
<size>
<width>550</width>
<height>411</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>550</width>
<height>411</height>
</size>
</property>
<property name="windowTitle">
<string>RAM info - melonDS</string>
</property>
<property name="modal">
<bool>false</bool>
</property>
<widget class="QGroupBox" name="groupBox">
<property name="geometry">
<rect>
<x>340</x>
<y>10</y>
<width>201</width>
<height>111</height>
</rect>
</property>
<property name="title">
<string>Search</string>
</property>
<widget class="QPushButton" name="btnSearch">
<property name="geometry">
<rect>
<x>130</x>
<y>20</y>
<width>61</width>
<height>23</height>
</rect>
</property>
<property name="text">
<string>Search</string>
</property>
</widget>
<widget class="QLineEdit" name="txtSearch">
<property name="geometry">
<rect>
<x>50</x>
<y>20</y>
<width>71</width>
<height>21</height>
</rect>
</property>
<property name="maxLength">
<number>5</number>
</property>
</widget>
<widget class="QPushButton" name="btnClear">
<property name="geometry">
<rect>
<x>120</x>
<y>80</y>
<width>71</width>
<height>23</height>
</rect>
</property>
<property name="text">
<string>Clear</string>
</property>
</widget>
<widget class="QLabel" name="labelValue">
<property name="geometry">
<rect>
<x>10</x>
<y>20</y>
<width>41</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>Value:</string>
</property>
</widget>
<widget class="QRadioButton" name="radiobtn1byte">
<property name="geometry">
<rect>
<x>10</x>
<y>50</y>
<width>90</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>1byte</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
<widget class="QRadioButton" name="radiobtn2bytes">
<property name="geometry">
<rect>
<x>10</x>
<y>70</y>
<width>90</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>2bytes</string>
</property>
</widget>
<widget class="QRadioButton" name="radiobtn4bytes">
<property name="geometry">
<rect>
<x>10</x>
<y>90</y>
<width>90</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>4bytes</string>
</property>
</widget>
</widget>
<widget class="QProgressBar" name="progressBar">
<property name="geometry">
<rect>
<x>10</x>
<y>380</y>
<width>321</width>
<height>23</height>
</rect>
</property>
<property name="maximum">
<number>100</number>
</property>
<property name="value">
<number>0</number>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
<property name="textVisible">
<bool>true</bool>
</property>
<property name="format">
<string>%p%</string>
</property>
</widget>
<widget class="QTableWidget" name="ramTable">
<property name="geometry">
<rect>
<x>10</x>
<y>30</y>
<width>321</width>
<height>341</height>
</rect>
</property>
<property name="minimumSize">
<size>
<width>321</width>
<height>341</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>321</width>
<height>341</height>
</size>
</property>
<property name="editTriggers">
<set>QAbstractItemView::AnyKeyPressed|QAbstractItemView::DoubleClicked</set>
</property>
<property name="alternatingRowColors">
<bool>true</bool>
</property>
<property name="selectionBehavior">
<enum>QAbstractItemView::SelectRows</enum>
</property>
<attribute name="verticalHeaderVisible">
<bool>false</bool>
</attribute>
<attribute name="verticalHeaderMinimumSectionSize">
<number>16</number>
</attribute>
<attribute name="verticalHeaderDefaultSectionSize">
<number>16</number>
</attribute>
<column>
<property name="text">
<string>Address</string>
</property>
</column>
<column>
<property name="text">
<string>Value</string>
</property>
</column>
<column>
<property name="text">
<string>Previous</string>
</property>
</column>
</widget>
<widget class="QLabel" name="txtFound">
<property name="geometry">
<rect>
<x>10</x>
<y>10</y>
<width>101</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>Found:</string>
</property>
</widget>
</widget>
<resources/>
<connections/>
</ui>