Merge lp:~fredoust/sudoku-app/fix-bug-1202084 into lp:sudoku-app
- fix-bug-1202084
- Merge into trunk
Proposed by
Frédéric Delgado
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Dinko Osmankovic | ||||
Approved revision: | 90 | ||||
Merged at revision: | 91 | ||||
Proposed branch: | lp:~fredoust/sudoku-app/fix-bug-1202084 | ||||
Merge into: | lp:sudoku-app | ||||
Diff against target: |
679 lines (+341/-325) 1 file modified
sudoku-app.qml (+341/-325) |
||||
To merge this branch: | bzr merge lp:~fredoust/sudoku-app/fix-bug-1202084 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ubuntu Phone Apps Jenkins Bot | continuous-integration | Approve | |
Dinko Osmankovic | Approve | ||
Review via email: mp+176065@code.launchpad.net |
Commit message
fix for bug 1202084 by changing defaultSheet to dialog with cancel button
Description of the change
fix for bug 1202084 by changing defaultSheet to dialog with cancel button
To post a comment you must log in.
Revision history for this message
Dinko Osmankovic (dinko-metalac) : | # |
review:
Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) : | # |
review:
Approve
(continuous-integration)
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'sudoku-app.qml' | |||
2 | --- sudoku-app.qml 2013-07-19 14:06:01 +0000 | |||
3 | +++ sudoku-app.qml 2013-07-21 16:06:26 +0000 | |||
4 | @@ -441,334 +441,350 @@ | |||
5 | 441 | 441 | ||
6 | 442 | Component { | 442 | Component { |
7 | 443 | id: profileSelector | 443 | id: profileSelector |
170 | 444 | DefaultSheet { | 444 | Dialog { |
171 | 445 | title: i18n.tr("Select profile") | 445 | title: i18n.tr("Select profile") |
172 | 446 | contentsHeight: mainView.height | 446 | |
173 | 447 | 447 | ||
174 | 448 | /* | 448 | |
175 | 449 | Column { | 449 | Column{ |
176 | 450 | anchors { | 450 | height: mainColumnSettings.height |
177 | 451 | top: parent.top | 451 | ListView { |
178 | 452 | left: parent.left | 452 | |
179 | 453 | right: parent.right | 453 | id: profileListView |
180 | 454 | } | 454 | clip: true |
181 | 455 | height: mainColumnSettings.height | 455 | width: parent.width |
182 | 456 | 456 | height: parent.height - units.gu(12) | |
183 | 457 | ListItem.Header { | 457 | model: profilesModel |
184 | 458 | id: header | 458 | |
185 | 459 | text: i18n.tr("Select profile") | 459 | delegate: |
186 | 460 | } | 460 | ListItem.Standard { |
187 | 461 | */ | 461 | |
188 | 462 | 462 | text: firstname + " " + lastname | |
189 | 463 | 463 | progression: true | |
190 | 464 | 464 | onTriggered: { | |
191 | 465 | ListView { | 465 | console.log("clicked "+index) |
192 | 466 | height: mainColumnSettings.height | 466 | currentUserId = profileId; |
193 | 467 | id: profileListView | 467 | hide() |
194 | 468 | clip: true | 468 | } |
195 | 469 | width: parent.width | 469 | } |
196 | 470 | // height: parent.height - header.height | 470 | |
197 | 471 | model: profilesModel | 471 | } |
198 | 472 | 472 | ||
199 | 473 | delegate: | 473 | SudokuDialogButton{ |
200 | 474 | ListItem.Standard { | 474 | |
201 | 475 | 475 | anchors.horizontalCenter: parent.horizontalCenter | |
202 | 476 | text: firstname + " " + lastname | 476 | id:cancelButton |
203 | 477 | progression: true | 477 | buttonText: i18n.tr("Cancel") |
204 | 478 | onTriggered: { | 478 | width: parent.width/2; |
205 | 479 | console.log("clicked "+index) | 479 | size: units.gu(5) |
206 | 480 | currentUserId = profileId; | 480 | buttonColor: sudokuBlocksGrid.dialogButtonColor1 |
207 | 481 | hide() | 481 | textColor: sudokuBlocksGrid.dialogButtonTextColor |
208 | 482 | } | 482 | //border.color: "transparent" |
209 | 483 | } | 483 | onTriggered: { |
210 | 484 | 484 | hide() | |
211 | 485 | } | 485 | } |
212 | 486 | } | 486 | } |
213 | 487 | // } | 487 | |
214 | 488 | } | 488 | } |
215 | 489 | 489 | } | |
216 | 490 | Component { | 490 | } |
217 | 491 | id: manageProfileSelector | 491 | |
218 | 492 | DefaultSheet { | 492 | Component { |
219 | 493 | title: i18n.tr("Select profile") | 493 | id: manageProfileSelector |
220 | 494 | contentsHeight: mainView.height | 494 | Dialog { |
221 | 495 | 495 | title: i18n.tr("Select profile") | |
222 | 496 | 496 | ||
223 | 497 | 497 | Column{ | |
224 | 498 | ListView { | 498 | height: mainColumnSettings.height |
225 | 499 | id: manageProfileListView | 499 | ListView { |
226 | 500 | clip: true | 500 | id: manageProfileListView |
227 | 501 | width: parent.width | 501 | clip: true |
228 | 502 | height: mainColumnSettings.height | 502 | width: parent.width |
229 | 503 | model: profilesModel | 503 | height: parent.height - units.gu(12) |
230 | 504 | 504 | model: profilesModel | |
231 | 505 | delegate: | 505 | |
232 | 506 | 506 | delegate: | |
233 | 507 | ListItem.Standard { | 507 | |
234 | 508 | 508 | ListItem.Standard { | |
235 | 509 | text: firstname + " " + lastname | 509 | |
236 | 510 | 510 | text: firstname + " " + lastname | |
237 | 511 | progression: true | 511 | |
238 | 512 | onTriggered: { | 512 | progression: true |
239 | 513 | hide() | 513 | onTriggered: { |
240 | 514 | editUserId = profileId | 514 | hide() |
241 | 515 | PopupUtils.open(manageProfileDialog, selectorProfile) | 515 | editUserId = profileId |
242 | 516 | } | 516 | PopupUtils.open(manageProfileDialog, selectorProfile) |
243 | 517 | } | 517 | } |
244 | 518 | 518 | } | |
245 | 519 | 519 | ||
246 | 520 | 520 | ||
247 | 521 | } | 521 | |
248 | 522 | } | 522 | } |
249 | 523 | } | 523 | SudokuDialogButton{ |
250 | 524 | 524 | ||
251 | 525 | ListModel{ | 525 | anchors.horizontalCenter: parent.horizontalCenter |
252 | 526 | id: profilesModel | 526 | id:cancelButton |
253 | 527 | } | 527 | buttonText: i18n.tr("Cancel") |
254 | 528 | 528 | width: parent.width/2; | |
255 | 529 | id: mainColumnSettings; | 529 | size: units.gu(5) |
256 | 530 | //width: settingsTab.width; | 530 | buttonColor: sudokuBlocksGrid.dialogButtonColor1 |
257 | 531 | //height: settingsTab.height; | 531 | textColor: sudokuBlocksGrid.dialogButtonTextColor |
258 | 532 | anchors.fill: parent | 532 | //border.color: "transparent" |
259 | 533 | //anchors.horizontalCenter: parent.horizontalCenter; | 533 | onTriggered: { |
260 | 534 | spacing: units.gu(1) | 534 | hide() |
261 | 535 | 535 | } | |
262 | 536 | ListItem.Header { | 536 | } |
263 | 537 | text: i18n.tr("<b>Sudoku settings</b>") | 537 | } |
264 | 538 | } | 538 | } |
265 | 539 | 539 | } | |
266 | 540 | ListItem.ValueSelector { | 540 | |
267 | 541 | objectName: "difficultySelector" | 541 | ListModel{ |
268 | 542 | id: difficultySelector | 542 | id: profilesModel |
269 | 543 | text: i18n.tr("Difficulty") | 543 | } |
270 | 544 | values: [i18n.tr("Easy"), i18n.tr("Moderate"), i18n.tr("Hard"), i18n.tr("Ultra Hard")] | 544 | |
271 | 545 | onSelectedIndexChanged: { | 545 | id: mainColumnSettings; |
272 | 546 | //print(difficultySelector.selectedIndex) | 546 | //width: settingsTab.width; |
273 | 547 | switch(difficultySelector.selectedIndex) { | 547 | //height: settingsTab.height; |
274 | 548 | case 0: | 548 | anchors.fill: parent |
275 | 549 | var randomnumber = Math.floor(Math.random()*9); | 549 | //anchors.horizontalCenter: parent.horizontalCenter; |
276 | 550 | randomnumber += 31; | 550 | spacing: units.gu(1) |
277 | 551 | sudokuBlocksGrid.createNewGame(81 - randomnumber); | 551 | |
278 | 552 | Settings.setSetting("Difficulty", selectedIndex) | 552 | ListItem.Header { |
279 | 553 | break; | 553 | text: i18n.tr("<b>Sudoku settings</b>") |
280 | 554 | case 1: | 554 | } |
281 | 555 | var randomnumber = Math.floor(Math.random()*4); | 555 | |
282 | 556 | randomnumber += 26; | 556 | ListItem.ValueSelector { |
283 | 557 | sudokuBlocksGrid.createNewGame(81 - randomnumber); | 557 | objectName: "difficultySelector" |
284 | 558 | Settings.setSetting("Difficulty", selectedIndex) | 558 | id: difficultySelector |
285 | 559 | break; | 559 | text: i18n.tr("Difficulty") |
286 | 560 | case 2: | 560 | values: [i18n.tr("Easy"), i18n.tr("Moderate"), i18n.tr("Hard"), i18n.tr("Ultra Hard")] |
287 | 561 | var randomnumber = Math.floor(Math.random()*4); | 561 | onSelectedIndexChanged: { |
288 | 562 | randomnumber += 21; | 562 | //print(difficultySelector.selectedIndex) |
289 | 563 | sudokuBlocksGrid.createNewGame(81 - randomnumber); | 563 | switch(difficultySelector.selectedIndex) { |
290 | 564 | Settings.setSetting("Difficulty", selectedIndex) | 564 | case 0: |
291 | 565 | break; | 565 | var randomnumber = Math.floor(Math.random()*9); |
292 | 566 | case 3: | 566 | randomnumber += 31; |
293 | 567 | var randomnumber = Math.floor(Math.random()*3); | 567 | sudokuBlocksGrid.createNewGame(81 - randomnumber); |
294 | 568 | randomnumber += 17; | 568 | Settings.setSetting("Difficulty", selectedIndex) |
295 | 569 | sudokuBlocksGrid.createNewGame(81 - randomnumber); | 569 | break; |
296 | 570 | Settings.setSetting("Difficulty", selectedIndex) | 570 | case 1: |
297 | 571 | break; | 571 | var randomnumber = Math.floor(Math.random()*4); |
298 | 572 | } | 572 | randomnumber += 26; |
299 | 573 | } | 573 | sudokuBlocksGrid.createNewGame(81 - randomnumber); |
300 | 574 | 574 | Settings.setSetting("Difficulty", selectedIndex) | |
301 | 575 | } | 575 | break; |
302 | 576 | ListItem.ValueSelector { | 576 | case 2: |
303 | 577 | id: themeSelector | 577 | var randomnumber = Math.floor(Math.random()*4); |
304 | 578 | text: i18n.tr("Theme") | 578 | randomnumber += 21; |
305 | 579 | values: ["UbuntuColours", "Simple"] | 579 | sudokuBlocksGrid.createNewGame(81 - randomnumber); |
306 | 580 | onSelectedIndexChanged: { | 580 | Settings.setSetting("Difficulty", selectedIndex) |
307 | 581 | var newColorScheme = null; | 581 | break; |
308 | 582 | if (selectedIndex == 0) | 582 | case 3: |
309 | 583 | { | 583 | var randomnumber = Math.floor(Math.random()*3); |
310 | 584 | //print("Ubuntu") | 584 | randomnumber += 17; |
311 | 585 | var result = Settings.setSetting("ColorTheme", selectedIndex); | 585 | sudokuBlocksGrid.createNewGame(81 - randomnumber); |
312 | 586 | //print(result); | 586 | Settings.setSetting("Difficulty", selectedIndex) |
313 | 587 | sudokuBlocksGrid.changeColorScheme("ColorSchemeUbuntu.qml"); | 587 | break; |
314 | 588 | } | 588 | } |
315 | 589 | if (selectedIndex == 1) | 589 | } |
316 | 590 | { | 590 | |
317 | 591 | //print("Simple") | 591 | } |
318 | 592 | var result = Settings.setSetting("ColorTheme", selectedIndex); | 592 | ListItem.ValueSelector { |
319 | 593 | //print(result); | 593 | id: themeSelector |
320 | 594 | sudokuBlocksGrid.changeColorScheme("ColorSchemeSimple.qml"); | 594 | text: i18n.tr("Theme") |
321 | 595 | } | 595 | values: ["UbuntuColours", "Simple"] |
322 | 596 | } | 596 | onSelectedIndexChanged: { |
323 | 597 | } | 597 | var newColorScheme = null; |
324 | 598 | 598 | if (selectedIndex == 0) | |
325 | 599 | ListItem.Standard { | 599 | { |
326 | 600 | objectName: "hintsSwitchClickable" | 600 | //print("Ubuntu") |
327 | 601 | text: i18n.tr("Hints") | 601 | var result = Settings.setSetting("ColorTheme", selectedIndex); |
328 | 602 | width: parent.width | 602 | //print(result); |
329 | 603 | control: Switch { | 603 | sudokuBlocksGrid.changeColorScheme("ColorSchemeUbuntu.qml"); |
330 | 604 | objectName: "hintsSwitch" | 604 | } |
331 | 605 | id: disableHints | 605 | if (selectedIndex == 1) |
332 | 606 | { | ||
333 | 607 | //print("Simple") | ||
334 | 608 | var result = Settings.setSetting("ColorTheme", selectedIndex); | ||
335 | 609 | //print(result); | ||
336 | 610 | sudokuBlocksGrid.changeColorScheme("ColorSchemeSimple.qml"); | ||
337 | 611 | } | ||
338 | 612 | } | ||
339 | 613 | } | ||
340 | 614 | |||
341 | 615 | ListItem.Standard { | ||
342 | 616 | objectName: "hintsSwitchClickable" | ||
343 | 617 | text: i18n.tr("Hints") | ||
344 | 618 | width: parent.width | ||
345 | 619 | control: Switch { | ||
346 | 620 | objectName: "hintsSwitch" | ||
347 | 621 | id: disableHints | ||
348 | 622 | anchors.horizontalCenter: parent.horizontalCenter | ||
349 | 623 | anchors.verticalCenter: parent.verticalCenter | ||
350 | 624 | checked: disableHintsChecked | ||
351 | 625 | onCheckedChanged: { | ||
352 | 626 | var result = Settings.setSetting("DisableHints", checked ? "true":"false"); | ||
353 | 627 | //print(result); | ||
354 | 628 | } | ||
355 | 629 | } | ||
356 | 630 | } | ||
357 | 631 | ListItem.Header { | ||
358 | 632 | text: i18n.tr("<b>Profiles settings</b>") | ||
359 | 633 | } | ||
360 | 634 | ListItem.SingleValue { | ||
361 | 635 | text: "Current profile" | ||
362 | 636 | id: selectorProfile | ||
363 | 637 | value: { | ||
364 | 638 | if(currentUserId==-1) | ||
365 | 639 | return i18n.tr("None") | ||
366 | 640 | else | ||
367 | 641 | return Settings.getUserFirstName(currentUserId)+" "+Settings.getUserLastName(currentUserId); | ||
368 | 642 | |||
369 | 643 | } | ||
370 | 644 | |||
371 | 645 | onClicked: { | ||
372 | 646 | |||
373 | 647 | var allProfiles = new Array(); | ||
374 | 648 | allProfiles = Settings.getAllProfiles() | ||
375 | 649 | |||
376 | 650 | profilesModel.clear() | ||
377 | 651 | |||
378 | 652 | for(var i = 0; i < allProfiles.length; i++) | ||
379 | 653 | { | ||
380 | 654 | profilesModel.append({"profileId":allProfiles[i].id,"lastname":allProfiles[i].lastname, "firstname":allProfiles[i].firstname}) | ||
381 | 655 | } | ||
382 | 656 | PopupUtils.open(profileSelector, selectorProfile) | ||
383 | 657 | } | ||
384 | 658 | } | ||
385 | 659 | |||
386 | 660 | AddProfileDialog{ | ||
387 | 661 | id:addProfileDialog | ||
388 | 662 | } | ||
389 | 663 | |||
390 | 664 | ManageProfileDialog{ | ||
391 | 665 | id:manageProfileDialog | ||
392 | 666 | } | ||
393 | 667 | |||
394 | 668 | |||
395 | 669 | ListItem.SingleValue { | ||
396 | 670 | id:addSingleValue | ||
397 | 671 | text: i18n.tr("Add profile") | ||
398 | 672 | onClicked: { | ||
399 | 673 | PopupUtils.open(addProfileDialog, addSingleValue); | ||
400 | 674 | } | ||
401 | 675 | } | ||
402 | 676 | |||
403 | 677 | ListItem.SingleValue { | ||
404 | 678 | id:manageProfileSingleValue | ||
405 | 679 | text: i18n.tr("Manage profiles") | ||
406 | 680 | onClicked: { | ||
407 | 681 | |||
408 | 682 | var allProfiles = new Array(); | ||
409 | 683 | allProfiles = Settings.getAllProfiles() | ||
410 | 684 | |||
411 | 685 | profilesModel.clear() | ||
412 | 686 | |||
413 | 687 | for(var i = 0; i < allProfiles.length; i++) | ||
414 | 688 | { | ||
415 | 689 | profilesModel.append({"profileId":allProfiles[i].id,"lastname":allProfiles[i].lastname, "firstname":allProfiles[i].firstname}) | ||
416 | 690 | } | ||
417 | 691 | |||
418 | 692 | PopupUtils.open(manageProfileSelector, manageProfileSingleValue) | ||
419 | 693 | } | ||
420 | 694 | } | ||
421 | 695 | |||
422 | 696 | |||
423 | 697 | } | ||
424 | 698 | } | ||
425 | 699 | |||
426 | 700 | |||
427 | 701 | } | ||
428 | 702 | |||
429 | 703 | Tab { | ||
430 | 704 | id: aboutTab; | ||
431 | 705 | objectName: "aboutTab" | ||
432 | 706 | title: i18n.tr("About") | ||
433 | 707 | page: Page { | ||
434 | 708 | |||
435 | 709 | Column { | ||
436 | 710 | id: aboutColumn; | ||
437 | 711 | spacing: 5; | ||
438 | 712 | //anchors.fill: parent | ||
439 | 713 | anchors.horizontalCenter: parent.horizontalCenter; | ||
440 | 714 | y: units.gu(8); | ||
441 | 715 | Image { | ||
442 | 716 | objectName: "aboutImage" | ||
443 | 717 | property real maxWidth: units.gu(100) | ||
444 | 606 | anchors.horizontalCenter: parent.horizontalCenter | 718 | anchors.horizontalCenter: parent.horizontalCenter |
607 | 607 | anchors.verticalCenter: parent.verticalCenter | 719 | width: Math.min(mainView.width, maxWidth)/1.75 |
608 | 608 | checked: disableHintsChecked | 720 | //height: width |
609 | 609 | onCheckedChanged: { | 721 | source: "icons/sudoko-vector-about.svg" |
610 | 610 | var result = Settings.setSetting("DisableHints", checked ? "true":"false"); | 722 | smooth: true |
611 | 611 | //print(result); | 723 | fillMode: Image.PreserveAspectFit |
612 | 612 | } | 724 | |
613 | 613 | } | 725 | } |
614 | 614 | } | 726 | Row { |
615 | 615 | ListItem.Header { | 727 | //anchors.horizontalCenter: parent.horizontalCenter; |
616 | 616 | text: i18n.tr("<b>Profiles settings</b>") | 728 | anchors.left: aboutColumn.left |
617 | 617 | } | 729 | Label { |
618 | 618 | ListItem.SingleValue { | 730 | objectName: "authorLabel" |
619 | 619 | text: "Current profile" | 731 | text: i18n.tr("Author(s): ") |
620 | 620 | id: selectorProfile | 732 | |
621 | 621 | value: { | 733 | } |
622 | 622 | if(currentUserId==-1) | 734 | Label { |
623 | 623 | return i18n.tr("None") | 735 | objectName: "authors" |
624 | 624 | else | 736 | font.bold: true; |
625 | 625 | return Settings.getUserFirstName(currentUserId)+" "+Settings.getUserLastName(currentUserId); | 737 | text: "Dinko Osmankovic\nFr\u00e9d\u00e9ric Delgado\nGeorgi Karavasilev" |
626 | 626 | 738 | } | |
627 | 627 | } | 739 | } |
628 | 628 | 740 | Row { | |
629 | 629 | onClicked: { | 741 | anchors.horizontalCenter: parent.horizontalCenter; |
630 | 630 | 742 | Label { | |
631 | 631 | var allProfiles = new Array(); | 743 | objectName: "contactLabel" |
632 | 632 | allProfiles = Settings.getAllProfiles() | 744 | text: i18n.tr("Contact: ") |
633 | 633 | 745 | } | |
634 | 634 | profilesModel.clear() | 746 | Label { |
635 | 635 | 747 | objectName: "contacts" | |
636 | 636 | for(var i = 0; i < allProfiles.length; i++) | 748 | font.bold: true; |
637 | 637 | { | 749 | text: "Dinko Osmankovic\nFrédéric Delgado\nGeorgi Karavasilev" |
638 | 638 | profilesModel.append({"profileId":allProfiles[i].id,"lastname":allProfiles[i].lastname, "firstname":allProfiles[i].firstname}) | 750 | } |
639 | 639 | } | 751 | } |
640 | 640 | PopupUtils.open(profileSelector, selectorProfile) | 752 | Row { |
641 | 641 | } | 753 | id: homepage; |
642 | 642 | } | 754 | anchors.horizontalCenter: parent.horizontalCenter; |
643 | 643 | 755 | Label { | |
644 | 644 | AddProfileDialog{ | 756 | objectName: "urlLabel" |
645 | 645 | id:addProfileDialog | 757 | font.bold: true; |
646 | 646 | } | 758 | text: "<a href=\"https://launchpad.net/sudoku-app\">https://launchpad.net/sudoku-app</a>" |
647 | 647 | 759 | onLinkActivated: Qt.openUrlExternally(link) | |
648 | 648 | ManageProfileDialog{ | 760 | } |
649 | 649 | id:manageProfileDialog | 761 | } |
650 | 650 | } | 762 | } |
651 | 651 | 763 | Row { | |
652 | 652 | 764 | anchors.horizontalCenter: parent.horizontalCenter; | |
653 | 653 | ListItem.SingleValue { | 765 | anchors.top: aboutColumn.bottom; |
654 | 654 | id:addSingleValue | 766 | anchors.topMargin: units.gu(5); |
655 | 655 | text: i18n.tr("Add profile") | 767 | Label { |
656 | 656 | onClicked: { | 768 | objectName: "versionLabel" |
657 | 657 | PopupUtils.open(addProfileDialog, addSingleValue); | 769 | text: i18n.tr("Version: ") |
658 | 658 | } | 770 | } |
659 | 659 | } | 771 | Label { |
660 | 660 | 772 | objectName: "version" | |
661 | 661 | ListItem.SingleValue { | 773 | font.bold: true; |
662 | 662 | id:manageProfileSingleValue | 774 | text: "0.4" |
663 | 663 | text: i18n.tr("Manage profiles") | 775 | } |
664 | 664 | onClicked: { | 776 | } |
665 | 665 | 777 | Row { | |
666 | 666 | var allProfiles = new Array(); | 778 | anchors.horizontalCenter: parent.horizontalCenter; |
667 | 667 | allProfiles = Settings.getAllProfiles() | 779 | anchors.top: aboutColumn.bottom; |
668 | 668 | 780 | anchors.topMargin: units.gu(8); | |
669 | 669 | profilesModel.clear() | 781 | Label { |
670 | 670 | 782 | objectName: "yearLabel" | |
671 | 671 | for(var i = 0; i < allProfiles.length; i++) | 783 | font.bold: true; |
672 | 672 | { | 784 | text: "2013" |
673 | 673 | profilesModel.append({"profileId":allProfiles[i].id,"lastname":allProfiles[i].lastname, "firstname":allProfiles[i].firstname}) | 785 | } |
512 | 674 | } | ||
513 | 675 | |||
514 | 676 | PopupUtils.open(manageProfileSelector, manageProfileSingleValue) | ||
515 | 677 | } | ||
516 | 678 | } | ||
517 | 679 | |||
518 | 680 | |||
519 | 681 | } | ||
520 | 682 | } | ||
521 | 683 | |||
522 | 684 | |||
523 | 685 | } | ||
524 | 686 | |||
525 | 687 | Tab { | ||
526 | 688 | id: aboutTab; | ||
527 | 689 | objectName: "aboutTab" | ||
528 | 690 | title: i18n.tr("About") | ||
529 | 691 | page: Page { | ||
530 | 692 | |||
531 | 693 | Column { | ||
532 | 694 | id: aboutColumn; | ||
533 | 695 | spacing: 5; | ||
534 | 696 | //anchors.fill: parent | ||
535 | 697 | anchors.horizontalCenter: parent.horizontalCenter; | ||
536 | 698 | y: units.gu(8); | ||
537 | 699 | Image { | ||
538 | 700 | objectName: "aboutImage" | ||
539 | 701 | property real maxWidth: units.gu(100) | ||
540 | 702 | anchors.horizontalCenter: parent.horizontalCenter | ||
541 | 703 | width: Math.min(mainView.width, maxWidth)/1.75 | ||
542 | 704 | //height: width | ||
543 | 705 | source: "icons/sudoko-vector-about.svg" | ||
544 | 706 | smooth: true | ||
545 | 707 | fillMode: Image.PreserveAspectFit | ||
546 | 708 | |||
547 | 709 | } | ||
548 | 710 | Row { | ||
549 | 711 | //anchors.horizontalCenter: parent.horizontalCenter; | ||
550 | 712 | anchors.left: aboutColumn.left | ||
551 | 713 | Label { | ||
552 | 714 | objectName: "authorLabel" | ||
553 | 715 | text: i18n.tr("Author(s): ") | ||
554 | 716 | |||
555 | 717 | } | ||
556 | 718 | Label { | ||
557 | 719 | objectName: "authors" | ||
558 | 720 | font.bold: true; | ||
559 | 721 | text: "Dinko Osmankovic\nFr\u00e9d\u00e9ric Delgado\nGeorgi Karavasilev" | ||
560 | 722 | } | ||
561 | 723 | } | ||
562 | 724 | Row { | ||
563 | 725 | anchors.horizontalCenter: parent.horizontalCenter; | ||
564 | 726 | Label { | ||
565 | 727 | objectName: "contactLabel" | ||
566 | 728 | text: i18n.tr("Contact: ") | ||
567 | 729 | } | ||
568 | 730 | Label { | ||
569 | 731 | objectName: "contacts" | ||
570 | 732 | font.bold: true; | ||
571 | 733 | text: "Dinko Osmankovic\nFrédéric Delgado\nGeorgi Karavasilev" | ||
572 | 734 | } | ||
573 | 735 | } | ||
574 | 736 | Row { | ||
575 | 737 | id: homepage; | ||
576 | 738 | anchors.horizontalCenter: parent.horizontalCenter; | ||
577 | 739 | Label { | ||
578 | 740 | objectName: "urlLabel" | ||
579 | 741 | font.bold: true; | ||
580 | 742 | text: "<a href=\"https://launchpad.net/sudoku-app\">https://launchpad.net/sudoku-app</a>" | ||
581 | 743 | onLinkActivated: Qt.openUrlExternally(link) | ||
582 | 744 | } | ||
583 | 745 | } | ||
584 | 746 | } | ||
585 | 747 | Row { | ||
586 | 748 | anchors.horizontalCenter: parent.horizontalCenter; | ||
587 | 749 | anchors.top: aboutColumn.bottom; | ||
588 | 750 | anchors.topMargin: units.gu(5); | ||
589 | 751 | Label { | ||
590 | 752 | objectName: "versionLabel" | ||
591 | 753 | text: i18n.tr("Version: ") | ||
592 | 754 | } | ||
593 | 755 | Label { | ||
594 | 756 | objectName: "version" | ||
595 | 757 | font.bold: true; | ||
596 | 758 | text: "0.4" | ||
597 | 759 | } | ||
598 | 760 | } | ||
599 | 761 | Row { | ||
600 | 762 | anchors.horizontalCenter: parent.horizontalCenter; | ||
601 | 763 | anchors.top: aboutColumn.bottom; | ||
602 | 764 | anchors.topMargin: units.gu(8); | ||
603 | 765 | Label { | ||
604 | 766 | objectName: "yearLabel" | ||
605 | 767 | font.bold: true; | ||
606 | 768 | text: "2013" | ||
674 | 769 | } | 786 | } |
675 | 770 | } | 787 | } |
676 | 771 | } | 788 | } |
677 | 772 | } | 789 | } |
678 | 773 | } | 790 | } |
679 | 774 | } |