Skip to content

Commit fc03057

Browse files
committed
Move account info to own tab
1 parent eff223e commit fc03057

9 files changed

+250
-139
lines changed

icons/person.png

1.61 KB
Loading

icons/[email protected]

2.32 KB
Loading

resources.qrc

+2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<RCC>
22
<qresource prefix="/">
3+
<file>icons/person.png</file>
4+
<file>icons/[email protected]</file>
35
<file>icons/[email protected]</file>
46
<file>icons/circle.png</file>
57
<file>icons/[email protected]</file>

src/AccountWidget.ui

+123
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ui version="4.0">
3+
<class>AccountWidget</class>
4+
<widget class="QWidget" name="AccountWidget">
5+
<property name="geometry">
6+
<rect>
7+
<x>0</x>
8+
<y>0</y>
9+
<width>394</width>
10+
<height>160</height>
11+
</rect>
12+
</property>
13+
<property name="minimumSize">
14+
<size>
15+
<width>0</width>
16+
<height>150</height>
17+
</size>
18+
</property>
19+
<property name="windowTitle">
20+
<string>Form</string>
21+
</property>
22+
<property name="styleSheet">
23+
<string notr="true">QLabel#importExportDescription,
24+
QLabel#startDescription,
25+
QLabel#updateDescription {
26+
font-size: 11px;
27+
color: #898989;
28+
}</string>
29+
</property>
30+
<layout class="QHBoxLayout" name="horizontalLayout">
31+
<item>
32+
<layout class="QFormLayout" name="formLayout">
33+
<property name="sizeConstraint">
34+
<enum>QLayout::SetDefaultConstraint</enum>
35+
</property>
36+
<property name="fieldGrowthPolicy">
37+
<enum>QFormLayout::FieldsStayAtSizeHint</enum>
38+
</property>
39+
<property name="rowWrapPolicy">
40+
<enum>QFormLayout::DontWrapRows</enum>
41+
</property>
42+
<property name="verticalSpacing">
43+
<number>4</number>
44+
</property>
45+
<item row="0" column="0">
46+
<widget class="QLabel" name="label">
47+
<property name="text">
48+
<string>Account</string>
49+
</property>
50+
</widget>
51+
</item>
52+
<item row="0" column="1">
53+
<widget class="QLabel" name="account">
54+
<property name="font">
55+
<font>
56+
<weight>75</weight>
57+
<bold>true</bold>
58+
</font>
59+
</property>
60+
<property name="text">
61+
<string>None</string>
62+
</property>
63+
</widget>
64+
</item>
65+
<item row="1" column="1">
66+
<widget class="QLabel" name="importExportDescription">
67+
<property name="minimumSize">
68+
<size>
69+
<width>0</width>
70+
<height>60</height>
71+
</size>
72+
</property>
73+
<property name="text">
74+
<string>Use export to back up your account or to import it on another device. You can use the account on multiple devices simultaneously.</string>
75+
</property>
76+
<property name="wordWrap">
77+
<bool>true</bool>
78+
</property>
79+
</widget>
80+
</item>
81+
<item row="2" column="1">
82+
<layout class="QHBoxLayout" name="horizontalLayout_2">
83+
<property name="spacing">
84+
<number>-1</number>
85+
</property>
86+
<property name="sizeConstraint">
87+
<enum>QLayout::SetDefaultConstraint</enum>
88+
</property>
89+
<property name="leftMargin">
90+
<number>0</number>
91+
</property>
92+
<property name="bottomMargin">
93+
<number>0</number>
94+
</property>
95+
<item>
96+
<widget class="QPushButton" name="exportAccountButton">
97+
<property name="text">
98+
<string>Export...</string>
99+
</property>
100+
<property name="autoDefault">
101+
<bool>false</bool>
102+
</property>
103+
</widget>
104+
</item>
105+
<item>
106+
<widget class="QPushButton" name="importAccountButton">
107+
<property name="text">
108+
<string>Import...</string>
109+
</property>
110+
<property name="autoDefault">
111+
<bool>false</bool>
112+
</property>
113+
</widget>
114+
</item>
115+
</layout>
116+
</item>
117+
</layout>
118+
</item>
119+
</layout>
120+
</widget>
121+
<resources/>
122+
<connections/>
123+
</ui>

src/MainWindow.ui

+33-2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22
<ui version="4.0">
33
<class>MainWindow</class>
44
<widget class="QMainWindow" name="MainWindow">
5+
<property name="geometry">
6+
<rect>
7+
<x>0</x>
8+
<y>0</y>
9+
<width>400</width>
10+
<height>150</height>
11+
</rect>
12+
</property>
513
<property name="minimumSize">
614
<size>
715
<width>400</width>
@@ -28,14 +36,15 @@
2836
<number>0</number>
2937
</property>
3038
<widget class="SettingsTab" name="settingsPage"/>
39+
<widget class="AccountTab" name="accountsPage"/>
3140
<widget class="ReplaysTab" name="replaysPage"/>
3241
<widget class="LogTab" name="logPage"/>
3342
<widget class="AboutTab" name="aboutPage"/>
3443
</widget>
3544
<widget class="QToolBar" name="toolBar">
3645
<property name="minimumSize">
3746
<size>
38-
<width>400</width>
47+
<width>0</width>
3948
<height>0</height>
4049
</size>
4150
</property>
@@ -58,6 +67,7 @@
5867
<bool>false</bool>
5968
</attribute>
6069
<addaction name="actionSettings"/>
70+
<addaction name="actionAccount"/>
6171
<addaction name="actionReplays"/>
6272
<addaction name="actionLog"/>
6373
<addaction name="actionAbout"/>
@@ -95,7 +105,7 @@
95105
</property>
96106
<property name="icon">
97107
<iconset resource="../resources.qrc">
98-
<normaloff>:/icons/info.png</normaloff>:/icons/info.png</iconset>
108+
<normaloff>:/icons/info@2x.png</normaloff>:/icons/info@2x.png</iconset>
99109
</property>
100110
<property name="text">
101111
<string>About</string>
@@ -119,6 +129,21 @@
119129
<string>Replays</string>
120130
</property>
121131
</action>
132+
<action name="actionAccount">
133+
<property name="checkable">
134+
<bool>true</bool>
135+
</property>
136+
<property name="icon">
137+
<iconset resource="../resources.qrc">
138+
<normaloff>:/icons/[email protected]</normaloff>:/icons/[email protected]</iconset>
139+
</property>
140+
<property name="text">
141+
<string>Account</string>
142+
</property>
143+
<property name="toolTip">
144+
<string>Account</string>
145+
</property>
146+
</action>
122147
</widget>
123148
<customwidgets>
124149
<customwidget>
@@ -145,6 +170,12 @@
145170
<header>src/window.h</header>
146171
<container>1</container>
147172
</customwidget>
173+
<customwidget>
174+
<class>AccountTab</class>
175+
<extends>QWidget</extends>
176+
<header>src/window.h</header>
177+
<container>1</container>
178+
</customwidget>
148179
</customwidgets>
149180
<resources>
150181
<include location="../resources.qrc"/>

src/SettingsWidget.ui

+9-88
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@
77
<x>0</x>
88
<y>0</y>
99
<width>400</width>
10-
<height>250</height>
10+
<height>180</height>
1111
</rect>
1212
</property>
1313
<property name="minimumSize">
1414
<size>
1515
<width>0</width>
16-
<height>250</height>
16+
<height>180</height>
1717
</size>
1818
</property>
1919
<property name="windowTitle">
@@ -36,107 +36,28 @@ QLabel#updateDescription {
3636
<property name="verticalSpacing">
3737
<number>4</number>
3838
</property>
39-
<item row="0" column="0">
40-
<widget class="QLabel" name="label">
41-
<property name="text">
42-
<string>Account</string>
43-
</property>
44-
</widget>
45-
</item>
46-
<item row="0" column="1">
47-
<widget class="QLabel" name="account">
48-
<property name="font">
49-
<font>
50-
<weight>75</weight>
51-
<bold>true</bold>
52-
</font>
53-
</property>
54-
<property name="text">
55-
<string>None</string>
56-
</property>
57-
</widget>
58-
</item>
59-
<item row="1" column="1">
60-
<widget class="QLabel" name="importExportDescription">
61-
<property name="text">
62-
<string>Use export to back up your account info or to import it on another device.</string>
63-
</property>
64-
<property name="wordWrap">
65-
<bool>true</bool>
66-
</property>
67-
</widget>
68-
</item>
69-
<item row="2" column="1">
70-
<layout class="QHBoxLayout" name="horizontalLayout_2">
71-
<property name="spacing">
72-
<number>-1</number>
73-
</property>
74-
<property name="sizeConstraint">
75-
<enum>QLayout::SetDefaultConstraint</enum>
76-
</property>
77-
<property name="leftMargin">
78-
<number>0</number>
79-
</property>
80-
<property name="bottomMargin">
81-
<number>0</number>
82-
</property>
83-
<item>
84-
<widget class="QPushButton" name="exportAccountButton">
85-
<property name="text">
86-
<string>Export...</string>
87-
</property>
88-
<property name="autoDefault">
89-
<bool>false</bool>
90-
</property>
91-
</widget>
92-
</item>
93-
<item>
94-
<widget class="QPushButton" name="importAccountButton">
95-
<property name="text">
96-
<string>Import...</string>
97-
</property>
98-
<property name="autoDefault">
99-
<bool>false</bool>
100-
</property>
101-
</widget>
102-
</item>
103-
</layout>
104-
</item>
105-
<item row="4" column="1">
106-
<spacer name="verticalSpacer">
107-
<property name="orientation">
108-
<enum>Qt::Vertical</enum>
109-
</property>
110-
<property name="sizeHint" stdset="0">
111-
<size>
112-
<width>20</width>
113-
<height>10</height>
114-
</size>
115-
</property>
116-
</spacer>
117-
</item>
118-
<item row="5" column="0">
39+
<item row="1" column="0">
11940
<widget class="QLabel" name="label_4">
12041
<property name="text">
12142
<string>System</string>
12243
</property>
12344
</widget>
12445
</item>
125-
<item row="5" column="1">
46+
<item row="1" column="1">
12647
<widget class="QCheckBox" name="startAtLogin">
12748
<property name="text">
12849
<string>Start at login </string>
12950
</property>
13051
</widget>
13152
</item>
132-
<item row="6" column="1">
53+
<item row="2" column="1">
13354
<widget class="QLabel" name="startDescription">
13455
<property name="text">
13556
<string>Open Track-o-Bot when you log in.</string>
13657
</property>
13758
</widget>
13859
</item>
139-
<item row="8" column="1">
60+
<item row="4" column="1">
14061
<spacer name="verticalSpacer_2">
14162
<property name="orientation">
14263
<enum>Qt::Vertical</enum>
@@ -149,21 +70,21 @@ QLabel#updateDescription {
14970
</property>
15071
</spacer>
15172
</item>
152-
<item row="9" column="1">
73+
<item row="5" column="1">
15374
<widget class="QCheckBox" name="checkForUpdates">
15475
<property name="text">
15576
<string>Check for updates</string>
15677
</property>
15778
</widget>
15879
</item>
159-
<item row="10" column="1">
80+
<item row="6" column="1">
16081
<widget class="QLabel" name="updateDescription">
16182
<property name="text">
16283
<string>Check for updates automatically.</string>
16384
</property>
16485
</widget>
16586
</item>
166-
<item row="11" column="1">
87+
<item row="7" column="1">
16788
<widget class="QPushButton" name="checkForUpdatesNowButton">
16889
<property name="enabled">
16990
<bool>true</bool>

0 commit comments

Comments
 (0)