Changeset View
Changeset View
Standalone View
Standalone View
krusader/Konfigurator/kgpanel.cpp
Show First 20 Lines • Show All 130 Lines • ▼ Show 20 Line(s) | 129 | KONFIGURATOR_CHECKBOX_PARAM tabbar_settings[] = { // cfg_class cfg_name default text restart tooltip | |||
---|---|---|---|---|---|
131 | {"Look&Feel", "Show Tab Buttons", true, i18n("Show new/close tab buttons"), true , i18n("Show the new/close tab buttons.") }, | 131 | {"Look&Feel", "Show Tab Buttons", true, i18n("Show new/close tab buttons"), true , i18n("Show the new/close tab buttons.") }, | ||
132 | }; | 132 | }; | ||
133 | cbs = createCheckBoxGroup(2, 0, tabbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | 133 | cbs = createCheckBoxGroup(2, 0, tabbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | ||
134 | gridLayout->addWidget(cbs, 0, 0, 1, 2); | 134 | gridLayout->addWidget(cbs, 0, 0, 1, 2); | ||
135 | 135 | | |||
136 | // ----------------- Tab Bar position ---------------------------------- | 136 | // ----------------- Tab Bar position ---------------------------------- | ||
137 | auto *hbox = new QHBoxLayout(); | 137 | auto *hbox = new QHBoxLayout(); | ||
138 | 138 | | |||
139 | hbox->addWidget(new QLabel(i18n("Tab Bar position:"), groupBox)); | 139 | QLabel *labelTabBar = new QLabel(i18n("Tab Bar position:"), groupBox); | ||
140 | hbox->addWidget(labelTabBar); | ||||
140 | 141 | | |||
141 | KONFIGURATOR_NAME_VALUE_PAIR positions[] = { | 142 | KONFIGURATOR_NAME_VALUE_PAIR positions[] = { | ||
142 | { i18n("Top"), "top" }, | 143 | { i18n("Top"), "top" }, | ||
143 | { i18n("Bottom"), "bottom" } | 144 | { i18n("Bottom"), "bottom" } | ||
144 | }; | 145 | }; | ||
145 | 146 | | |||
146 | KonfiguratorComboBox *cmb = createComboBox("Look&Feel", "Tab Bar Position", | 147 | KonfiguratorComboBox *cmb = createComboBox("Look&Feel", "Tab Bar Position", | ||
147 | "bottom", positions, 2, groupBox, true, false, | 148 | "bottom", positions, 2, labelTabBar, groupBox, true, false, | ||
148 | QString(), PAGE_GENERAL); | 149 | QString(), PAGE_GENERAL); | ||
149 | 150 | | |||
150 | hbox->addWidget(cmb); | 151 | hbox->addWidget(cmb); | ||
151 | gridLayout->addLayout(hbox, 1, 0, Qt::AlignLeft); | 152 | gridLayout->addLayout(hbox, 1, 0, Qt::AlignLeft); | ||
152 | 153 | | |||
153 | // ----------------- Show Tab bar ---------------------------------- | 154 | // ----------------- Show Tab bar ---------------------------------- | ||
154 | KonfiguratorCheckBox *checkBox = createCheckBox("Look&Feel", "Show Tab Bar On Single Tab", true, | 155 | KonfiguratorCheckBox *checkBox = createCheckBox("Look&Feel", "Show Tab Bar On Single Tab", true, | ||
155 | i18n("Show Tab Bar on single tab"), groupBox, | 156 | i18n("Show Tab Bar on single tab"), groupBox, | ||
Show All 16 Lines | 164 | // --------------------------------------------------------------------------------------- | |||
172 | }; | 173 | }; | ||
173 | 174 | | |||
174 | cbs = createCheckBoxGroup(2, 0, quicksearch, 4 /*count*/, groupBox, PAGE_GENERAL); | 175 | cbs = createCheckBoxGroup(2, 0, quicksearch, 4 /*count*/, groupBox, PAGE_GENERAL); | ||
175 | gridLayout->addWidget(cbs, 0, 0, 1, -1); | 176 | gridLayout->addWidget(cbs, 0, 0, 1, -1); | ||
176 | 177 | | |||
177 | // -------------- Search bar position ----------------------- | 178 | // -------------- Search bar position ----------------------- | ||
178 | 179 | | |||
179 | hbox = new QHBoxLayout(); | 180 | hbox = new QHBoxLayout(); | ||
180 | hbox->addWidget(new QLabel(i18n("Position:"), groupBox)); | 181 | QLabel *labelPosit = new QLabel(i18n("Position:"), groupBox); | ||
182 | hbox->addWidget(labelPosit); | ||||
181 | cmb = createComboBox("Look&Feel", "Quicksearch Position", | 183 | cmb = createComboBox("Look&Feel", "Quicksearch Position", | ||
182 | "bottom", positions, 2, groupBox, true, false, | 184 | "bottom", positions, 2, labelPosit, groupBox, true, false, | ||
183 | QString(), PAGE_GENERAL); | 185 | QString(), PAGE_GENERAL); | ||
184 | hbox->addWidget(cmb); | 186 | hbox->addWidget(cmb); | ||
185 | hbox->addWidget(createSpacer(groupBox)); | 187 | hbox->addWidget(createSpacer(groupBox)); | ||
186 | gridLayout->addLayout(hbox, 1, 0); | 188 | gridLayout->addLayout(hbox, 1, 0); | ||
187 | 189 | | |||
188 | // -------------- Default search mode ----------------------- | 190 | // -------------- Default search mode ----------------------- | ||
189 | 191 | | |||
190 | hbox = new QHBoxLayout(); | 192 | hbox = new QHBoxLayout(); | ||
191 | hbox->addWidget(new QLabel(i18n("Default mode:"), groupBox)); | 193 | QLabel *labelMode = new QLabel(i18n("Default mode:"), groupBox); | ||
194 | hbox->addWidget(labelMode); | ||||
192 | KONFIGURATOR_NAME_VALUE_PAIR modes[] = { | 195 | KONFIGURATOR_NAME_VALUE_PAIR modes[] = { | ||
193 | {i18n("Search"), QString::number(KrSearchBar::MODE_SEARCH)}, | 196 | {i18n("Search"), QString::number(KrSearchBar::MODE_SEARCH)}, | ||
194 | {i18n("Select"), QString::number(KrSearchBar::MODE_SELECT)}, | 197 | {i18n("Select"), QString::number(KrSearchBar::MODE_SELECT)}, | ||
195 | {i18n("Filter"), QString::number(KrSearchBar::MODE_FILTER)}}; | 198 | {i18n("Filter"), QString::number(KrSearchBar::MODE_FILTER)}}; | ||
196 | cmb = createComboBox("Look&Feel", "Default Search Mode", | 199 | cmb = createComboBox("Look&Feel", "Default Search Mode", | ||
197 | QString::number(KrSearchBar::MODE_SEARCH), modes, 3, groupBox, true, false, | 200 | QString::number(KrSearchBar::MODE_SEARCH), modes, 3, | ||
198 | QString(), PAGE_GENERAL); | 201 | labelMode, groupBox, true, false, | ||
199 | cmb->setToolTip(i18n("Set the default mode on first usage")); | 202 | i18n("Set the default mode on first usage"), PAGE_GENERAL); | ||
200 | hbox->addWidget(cmb); | 203 | hbox->addWidget(cmb); | ||
201 | hbox->addWidget(createSpacer(groupBox)); | 204 | hbox->addWidget(createSpacer(groupBox)); | ||
202 | gridLayout->addLayout(hbox, 1, 1); | 205 | gridLayout->addLayout(hbox, 1, 1); | ||
203 | 206 | | |||
204 | layout->addWidget(groupBox); | 207 | layout->addWidget(groupBox); | ||
205 | 208 | | |||
206 | // -------------------------------------------------------------------------------------------- | 209 | // -------------------------------------------------------------------------------------------- | ||
207 | // ------------------------------- Bookmark search settings ---------------------------------- | 210 | // ------------------------------- Bookmark search settings ---------------------------------- | ||
▲ Show 20 Lines • Show All 52 Lines • ▼ Show 20 Line(s) | 247 | { | |||
260 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | 263 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | ||
261 | grid->addWidget(l, 0, 0); | 264 | grid->addWidget(l, 0, 0); | ||
262 | auto *layouts = new KONFIGURATOR_NAME_VALUE_PAIR[numLayouts]; | 265 | auto *layouts = new KONFIGURATOR_NAME_VALUE_PAIR[numLayouts]; | ||
263 | for (int i = 0; i != numLayouts; i++) { | 266 | for (int i = 0; i != numLayouts; i++) { | ||
264 | layouts[ i ].text = KrLayoutFactory::layoutDescription(layoutNames[i]); | 267 | layouts[ i ].text = KrLayoutFactory::layoutDescription(layoutNames[i]); | ||
265 | layouts[ i ].value = layoutNames[i]; | 268 | layouts[ i ].value = layoutNames[i]; | ||
266 | } | 269 | } | ||
267 | KonfiguratorComboBox *cmb = createComboBox("PanelLayout", "Layout", "default", | 270 | KonfiguratorComboBox *cmb = createComboBox("PanelLayout", "Layout", "default", | ||
268 | layouts, numLayouts, tab, true, false, | 271 | layouts, numLayouts, l, tab, true, false, | ||
269 | QString(), PAGE_LAYOUT); | 272 | QString(), PAGE_LAYOUT); | ||
270 | grid->addWidget(cmb, 0, 1); | 273 | grid->addWidget(cmb, 0, 1); | ||
271 | delete [] layouts; | 274 | delete [] layouts; | ||
272 | 275 | | |||
273 | l = new QLabel(i18n("Frame Color:"), tab); | 276 | l = new QLabel(i18n("Frame Color:"), tab); | ||
274 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | 277 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | ||
275 | grid->addWidget(l, 1, 0); | 278 | grid->addWidget(l, 1, 0); | ||
276 | KONFIGURATOR_NAME_VALUE_PAIR frameColor[] = { | 279 | KONFIGURATOR_NAME_VALUE_PAIR frameColor[] = { | ||
277 | { i18nc("Frame color", "Defined by Layout"), "default" }, | 280 | { i18nc("Frame color", "Defined by Layout"), "default" }, | ||
278 | { i18nc("Frame color", "None"), "none" }, | 281 | { i18nc("Frame color", "None"), "none" }, | ||
279 | { i18nc("Frame color", "Statusbar"), "Statusbar" } | 282 | { i18nc("Frame color", "Statusbar"), "Statusbar" } | ||
280 | }; | 283 | }; | ||
281 | cmb = createComboBox("PanelLayout", "FrameColor", | 284 | cmb = createComboBox("PanelLayout", "FrameColor", | ||
282 | "default", frameColor, 3, tab, true, false, | 285 | "default", frameColor, 3, l, tab, true, false, | ||
283 | QString(), PAGE_LAYOUT); | 286 | QString(), PAGE_LAYOUT); | ||
284 | grid->addWidget(cmb, 1, 1); | 287 | grid->addWidget(cmb, 1, 1); | ||
285 | 288 | | |||
286 | 289 | | |||
287 | l = new QLabel(i18n("Frame Shape:"), tab); | 290 | l = new QLabel(i18n("Frame Shape:"), tab); | ||
288 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | 291 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | ||
289 | grid->addWidget(l, 2, 0); | 292 | grid->addWidget(l, 2, 0); | ||
290 | KONFIGURATOR_NAME_VALUE_PAIR frameShape[] = { | 293 | KONFIGURATOR_NAME_VALUE_PAIR frameShape[] = { | ||
291 | { i18nc("Frame shape", "Defined by Layout"), "default" }, | 294 | { i18nc("Frame shape", "Defined by Layout"), "default" }, | ||
292 | { i18nc("Frame shape", "None"), "NoFrame" }, | 295 | { i18nc("Frame shape", "None"), "NoFrame" }, | ||
293 | { i18nc("Frame shape", "Box"), "Box" }, | 296 | { i18nc("Frame shape", "Box"), "Box" }, | ||
294 | { i18nc("Frame shape", "Panel"), "Panel" }, | 297 | { i18nc("Frame shape", "Panel"), "Panel" }, | ||
295 | }; | 298 | }; | ||
296 | cmb = createComboBox("PanelLayout", "FrameShape", | 299 | cmb = createComboBox("PanelLayout", "FrameShape", | ||
297 | "default", frameShape, 4, tab, true, false, | 300 | "default", frameShape, 4, l, tab, true, false, | ||
298 | QString(), PAGE_LAYOUT); | 301 | QString(), PAGE_LAYOUT); | ||
299 | grid->addWidget(cmb, 2, 1); | 302 | grid->addWidget(cmb, 2, 1); | ||
300 | 303 | | |||
301 | 304 | | |||
302 | l = new QLabel(i18n("Frame Shadow:"), tab); | 305 | l = new QLabel(i18n("Frame Shadow:"), tab); | ||
303 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | 306 | l->setAlignment(Qt::AlignRight | Qt::AlignVCenter); | ||
304 | grid->addWidget(l, 3, 0); | 307 | grid->addWidget(l, 3, 0); | ||
305 | KONFIGURATOR_NAME_VALUE_PAIR frameShadow[] = { | 308 | KONFIGURATOR_NAME_VALUE_PAIR frameShadow[] = { | ||
306 | { i18nc("Frame shadow", "Defined by Layout"), "default" }, | 309 | { i18nc("Frame shadow", "Defined by Layout"), "default" }, | ||
307 | { i18nc("Frame shadow", "None"), "Plain" }, | 310 | { i18nc("Frame shadow", "None"), "Plain" }, | ||
308 | { i18nc("Frame shadow", "Raised"), "Raised" }, | 311 | { i18nc("Frame shadow", "Raised"), "Raised" }, | ||
309 | { i18nc("Frame shadow", "Sunken"), "Sunken" }, | 312 | { i18nc("Frame shadow", "Sunken"), "Sunken" }, | ||
310 | }; | 313 | }; | ||
311 | cmb = createComboBox("PanelLayout", "FrameShadow", | 314 | cmb = createComboBox("PanelLayout", "FrameShadow", | ||
312 | "default", frameShadow, 4, tab, true, false, | 315 | "default", frameShadow, 4, l, tab, true, false, | ||
313 | QString(), PAGE_LAYOUT); | 316 | QString(), PAGE_LAYOUT); | ||
314 | grid->addWidget(cmb, 3, 1); | 317 | grid->addWidget(cmb, 3, 1); | ||
315 | } | 318 | } | ||
316 | 319 | | |||
317 | void KgPanel::setupView(KrViewInstance *instance, QWidget *parent) | 320 | void KgPanel::setupView(KrViewInstance *instance, QWidget *parent) | ||
318 | { | 321 | { | ||
319 | QGridLayout *grid = createGridLayout(parent); | 322 | QGridLayout *grid = createGridLayout(parent); | ||
320 | 323 | | |||
321 | // -------------------- Filelist icon size ---------------------------------- | 324 | // -------------------- Filelist icon size ---------------------------------- | ||
322 | auto *hbox = new QHBoxLayout(); | 325 | auto *hbox = new QHBoxLayout(); | ||
323 | 326 | | |||
324 | hbox->addWidget(new QLabel(i18n("Default icon size:"), parent)); | 327 | QLabel *labelIconSize = new QLabel(i18n("Default icon size:"), parent); | ||
328 | hbox->addWidget(labelIconSize); | ||||
325 | 329 | | |||
326 | auto *iconSizes = new KONFIGURATOR_NAME_VALUE_PAIR[KrView::iconSizes.count()]; | 330 | auto *iconSizes = new KONFIGURATOR_NAME_VALUE_PAIR[KrView::iconSizes.count()]; | ||
327 | for(int i = 0; i < KrView::iconSizes.count(); i++) | 331 | for(int i = 0; i < KrView::iconSizes.count(); i++) | ||
328 | iconSizes[i].text = iconSizes[i].value = QString::number(KrView::iconSizes[i]); | 332 | iconSizes[i].text = iconSizes[i].value = QString::number(KrView::iconSizes[i]); | ||
329 | KonfiguratorComboBox *cmb = createComboBox(instance->name(), "IconSize", _FilelistIconSize, | 333 | KonfiguratorComboBox *cmb = createComboBox(instance->name(), "IconSize", _FilelistIconSize, | ||
330 | iconSizes, KrView::iconSizes.count(), parent, true, true, | 334 | iconSizes, KrView::iconSizes.count(), labelIconSize, | ||
331 | QString(), PAGE_VIEW); | 335 | parent, true, true, QString(), PAGE_VIEW); | ||
332 | delete [] iconSizes; | 336 | delete [] iconSizes; | ||
333 | cmb->lineEdit()->setValidator(new QRegExpValidator(QRegExp("[1-9]\\d{0,1}"), cmb)); | 337 | cmb->lineEdit()->setValidator(new QRegExpValidator(QRegExp("[1-9]\\d{0,1}"), cmb)); | ||
334 | hbox->addWidget(cmb); | 338 | hbox->addWidget(cmb); | ||
335 | 339 | | |||
336 | hbox->addWidget(createSpacer(parent)); | 340 | hbox->addWidget(createSpacer(parent)); | ||
337 | 341 | | |||
338 | grid->addLayout(hbox, 1, 0); | 342 | grid->addLayout(hbox, 1, 0); | ||
339 | 343 | | |||
▲ Show 20 Lines • Show All 78 Lines • ▼ Show 20 Line(s) | 361 | { | |||
418 | 422 | | |||
419 | // ========================================================= | 423 | // ========================================================= | ||
420 | panelGrid->addWidget(createLine(panelGrp), 4, 0); | 424 | panelGrid->addWidget(createLine(panelGrp), 4, 0); | ||
421 | 425 | | |||
422 | // ------------------------ Sort Method ---------------------------------- | 426 | // ------------------------ Sort Method ---------------------------------- | ||
423 | 427 | | |||
424 | hbox = new QHBoxLayout(); | 428 | hbox = new QHBoxLayout(); | ||
425 | 429 | | |||
426 | hbox->addWidget(new QLabel(i18n("Sort method:"), panelGrp)); | 430 | QLabel *labelSort = new QLabel(i18n("Sort method:"), panelGrp); | ||
431 | hbox->addWidget(labelSort); | ||||
427 | 432 | | |||
428 | KONFIGURATOR_NAME_VALUE_PAIR sortMethods[] = {{ i18n("Alphabetical"), QString::number(KrViewProperties::Alphabetical) }, | 433 | KONFIGURATOR_NAME_VALUE_PAIR sortMethods[] = {{ i18n("Alphabetical"), QString::number(KrViewProperties::Alphabetical) }, | ||
429 | { i18n("Alphabetical and numbers"), QString::number(KrViewProperties::AlphabeticalNumbers) }, | 434 | { i18n("Alphabetical and numbers"), QString::number(KrViewProperties::AlphabeticalNumbers) }, | ||
430 | { i18n("Character code"), QString::number(KrViewProperties::CharacterCode) }, | 435 | { i18n("Character code"), QString::number(KrViewProperties::CharacterCode) }, | ||
431 | { i18n("Character code and numbers"), QString::number(KrViewProperties::CharacterCodeNumbers) }, | 436 | { i18n("Character code and numbers"), QString::number(KrViewProperties::CharacterCodeNumbers) }, | ||
432 | { i18nc("Krusader sort", "Krusader"), QString::number(KrViewProperties::Krusader) } | 437 | { i18nc("Krusader sort", "Krusader"), QString::number(KrViewProperties::Krusader) } | ||
433 | }; | 438 | }; | ||
434 | KonfiguratorComboBox *cmb = createComboBox("Look&Feel", "Sort method", QString::number(_DefaultSortMethod), | 439 | KonfiguratorComboBox *cmb = createComboBox("Look&Feel", "Sort method", QString::number(_DefaultSortMethod), | ||
435 | sortMethods, 5, panelGrp, true, false, | 440 | sortMethods, 5, labelSort, panelGrp, true, false, | ||
436 | QString(), PAGE_VIEW); | 441 | QString(), PAGE_VIEW); | ||
437 | hbox->addWidget(cmb); | 442 | hbox->addWidget(cmb); | ||
438 | hbox->addWidget(createSpacer(panelGrp)); | 443 | hbox->addWidget(createSpacer(panelGrp)); | ||
439 | 444 | | |||
440 | panelGrid->addLayout(hbox, 5, 0); | 445 | panelGrid->addLayout(hbox, 5, 0); | ||
441 | 446 | | |||
442 | // ------------------------ Sort Options ---------------------------------- | 447 | // ------------------------ Sort Options ---------------------------------- | ||
443 | KONFIGURATOR_CHECKBOX_PARAM sortSettings[] = | 448 | KONFIGURATOR_CHECKBOX_PARAM sortSettings[] = | ||
Show All 21 Lines | |||||
465 | 470 | | |||
466 | panelGrp = createFrame(i18n("View modes"), tab_panel); | 471 | panelGrp = createFrame(i18n("View modes"), tab_panel); | ||
467 | panelLayout->addWidget(panelGrp, 1, 0); | 472 | panelLayout->addWidget(panelGrp, 1, 0); | ||
468 | panelGrid = createGridLayout(panelGrp); | 473 | panelGrid = createGridLayout(panelGrp); | ||
469 | 474 | | |||
470 | // -------------------- Default Panel Type ---------------------------------- | 475 | // -------------------- Default Panel Type ---------------------------------- | ||
471 | hbox = new QHBoxLayout(); | 476 | hbox = new QHBoxLayout(); | ||
472 | 477 | | |||
473 | hbox->addWidget(new QLabel(i18n("Default view mode:"), panelGrp)); | 478 | QLabel *labelViewMode = new QLabel(i18n("Default view mode:"), panelGrp); | ||
479 | hbox->addWidget(labelViewMode); | ||||
474 | 480 | | |||
475 | QList<KrViewInstance *> views = KrViewFactory::registeredViews(); | 481 | QList<KrViewInstance *> views = KrViewFactory::registeredViews(); | ||
476 | const int viewsSize = views.size(); | 482 | const int viewsSize = views.size(); | ||
477 | auto *panelTypes = new KONFIGURATOR_NAME_VALUE_PAIR[ viewsSize ]; | 483 | auto *panelTypes = new KONFIGURATOR_NAME_VALUE_PAIR[ viewsSize ]; | ||
478 | 484 | | |||
479 | QString defType = QString('0'); | 485 | QString defType = QString('0'); | ||
480 | 486 | | |||
481 | for (int i = 0; i != viewsSize; i++) { | 487 | for (int i = 0; i != viewsSize; i++) { | ||
482 | KrViewInstance * inst = views[ i ]; | 488 | KrViewInstance * inst = views[ i ]; | ||
483 | panelTypes[ i ].text = inst->description(); | 489 | panelTypes[ i ].text = inst->description(); | ||
484 | panelTypes[ i ].text.remove('&'); | 490 | panelTypes[ i ].text.remove('&'); | ||
485 | panelTypes[ i ].value = QString("%1").arg(inst->id()); | 491 | panelTypes[ i ].value = QString("%1").arg(inst->id()); | ||
486 | if (inst->id() == KrViewFactory::defaultViewId()) | 492 | if (inst->id() == KrViewFactory::defaultViewId()) | ||
487 | defType = QString("%1").arg(inst->id()); | 493 | defType = QString("%1").arg(inst->id()); | ||
488 | } | 494 | } | ||
489 | 495 | | |||
490 | cmb = createComboBox("Look&Feel", "Default Panel Type", defType, | 496 | cmb = createComboBox("Look&Feel", "Default Panel Type", defType, | ||
491 | panelTypes, viewsSize, panelGrp, false, false, | 497 | panelTypes, viewsSize, labelViewMode, panelGrp, | ||
492 | QString(), PAGE_VIEW); | 498 | false, false, QString(), PAGE_VIEW); | ||
493 | hbox->addWidget(cmb); | 499 | hbox->addWidget(cmb); | ||
494 | hbox->addWidget(createSpacer(panelGrp)); | 500 | hbox->addWidget(createSpacer(panelGrp)); | ||
495 | 501 | | |||
496 | delete [] panelTypes; | 502 | delete [] panelTypes; | ||
497 | 503 | | |||
498 | panelGrid->addLayout(hbox, 0, 0); | 504 | panelGrid->addLayout(hbox, 0, 0); | ||
499 | 505 | | |||
500 | // ----- Individual Settings Per View Type ------------------------ | 506 | // ----- Individual Settings Per View Type ------------------------ | ||
▲ Show 20 Lines • Show All 198 Lines • ▼ Show 20 Line(s) | 687 | { | |||
699 | }; | 705 | }; | ||
700 | KonfiguratorCheckBoxGroup *mediaMenuCheckBoxes = | 706 | KonfiguratorCheckBoxGroup *mediaMenuCheckBoxes = | ||
701 | createCheckBoxGroup(1, 0, mediaMenuParams, | 707 | createCheckBoxGroup(1, 0, mediaMenuParams, | ||
702 | sizeof(mediaMenuParams) / sizeof(*mediaMenuParams), | 708 | sizeof(mediaMenuParams) / sizeof(*mediaMenuParams), | ||
703 | tab, PAGE_MEDIA_MENU); | 709 | tab, PAGE_MEDIA_MENU); | ||
704 | tabLayout->addWidget(mediaMenuCheckBoxes, 0, nullptr); | 710 | tabLayout->addWidget(mediaMenuCheckBoxes, 0, nullptr); | ||
705 | 711 | | |||
706 | auto *showSizeHBox = new QHBoxLayout(); | 712 | auto *showSizeHBox = new QHBoxLayout(); | ||
707 | showSizeHBox->addWidget(new QLabel(i18n("Show Size:"), tab)); | 713 | QLabel *labelShowSize = new QLabel(i18n("Show Size:"), tab); | ||
714 | showSizeHBox->addWidget(labelShowSize); | ||||
708 | KONFIGURATOR_NAME_VALUE_PAIR showSizeValues[] = { | 715 | KONFIGURATOR_NAME_VALUE_PAIR showSizeValues[] = { | ||
709 | { i18nc("setting 'show size'", "Always"), "Always" }, | 716 | { i18nc("setting 'show size'", "Always"), "Always" }, | ||
710 | { i18nc("setting 'show size'", "When Device has no Label"), "WhenNoLabel" }, | 717 | { i18nc("setting 'show size'", "When Device has no Label"), "WhenNoLabel" }, | ||
711 | { i18nc("setting 'show size'", "Never"), "Never" }, | 718 | { i18nc("setting 'show size'", "Never"), "Never" }, | ||
712 | }; | 719 | }; | ||
713 | KonfiguratorComboBox *showSizeCmb = | 720 | KonfiguratorComboBox *showSizeCmb = | ||
714 | createComboBox("MediaMenu", "ShowSize", | 721 | createComboBox("MediaMenu", "ShowSize", | ||
715 | "Always", showSizeValues, | 722 | "Always", showSizeValues, | ||
716 | sizeof(showSizeValues) / sizeof(*showSizeValues), | 723 | sizeof(showSizeValues) / sizeof(*showSizeValues), | ||
717 | tab, false, false, | 724 | labelShowSize, tab, false, false, | ||
718 | QString(), PAGE_MEDIA_MENU); | 725 | QString(), PAGE_MEDIA_MENU); | ||
719 | showSizeHBox->addWidget(showSizeCmb); | 726 | showSizeHBox->addWidget(showSizeCmb); | ||
720 | createIgnoredMountpointsList(tab, tabLayout); | 727 | createIgnoredMountpointsList(tab, tabLayout); | ||
721 | showSizeHBox->addStretch(); | 728 | showSizeHBox->addStretch(); | ||
722 | tabLayout->addLayout(showSizeHBox); | 729 | tabLayout->addLayout(showSizeHBox); | ||
723 | 730 | | |||
724 | tabLayout->addStretch(); | 731 | tabLayout->addStretch(); | ||
725 | } | 732 | } | ||
▲ Show 20 Lines • Show All 111 Lines • Show Last 20 Lines |