-rw-r--r-- | noncore/settings/appearance2/appearance.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/noncore/settings/appearance2/appearance.cpp b/noncore/settings/appearance2/appearance.cpp index 6b9fe4d..f918767 100644 --- a/noncore/settings/appearance2/appearance.cpp +++ b/noncore/settings/appearance2/appearance.cpp | |||
@@ -668,48 +668,48 @@ void Appearance::colorClicked ( int index ) | |||
668 | m_color_changed |= ( item-> palette ( ) != qApp-> palette ( )); | 668 | m_color_changed |= ( item-> palette ( ) != qApp-> palette ( )); |
669 | } | 669 | } |
670 | 670 | ||
671 | 671 | ||
672 | void Appearance::editSchemeClicked ( ) | 672 | void Appearance::editSchemeClicked ( ) |
673 | { | 673 | { |
674 | ColorListItem *item = (ColorListItem *) m_color_list-> item ( m_color_list-> currentItem ( )); | 674 | ColorListItem *item = (ColorListItem *) m_color_list-> item ( m_color_list-> currentItem ( )); |
675 | 675 | ||
676 | int cnt = 0; | 676 | int cnt = 0; |
677 | QString labels [QColorGroup::NColorRoles]; | 677 | QString labels [QColorGroup::NColorRoles]; |
678 | QColor colors [QColorGroup::NColorRoles]; | 678 | QColor colors [QColorGroup::NColorRoles]; |
679 | 679 | ||
680 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) | 680 | for ( int role = 0; role < (int) QColorGroup::NColorRoles; ++role ) |
681 | { | 681 | { |
682 | QColor col = item-> color ( role ); | 682 | QColor col = item->color( static_cast<QColorGroup::ColorRole>( role ) ); |
683 | 683 | ||
684 | if ( col. isValid ( )) | 684 | if ( col. isValid ( )) |
685 | { | 685 | { |
686 | labels [cnt] = item-> label ( role ); | 686 | labels[cnt] = item->label( static_cast<QColorGroup::ColorRole>( role ) ); |
687 | colors [cnt] = col; | 687 | colors[cnt] = col; |
688 | 688 | ||
689 | cnt++; | 689 | cnt++; |
690 | } | 690 | } |
691 | } | 691 | } |
692 | 692 | ||
693 | EditScheme* editdlg = new EditScheme( cnt, labels, colors, this, "editScheme", true ); | 693 | EditScheme* editdlg = new EditScheme( cnt, labels, colors, this, "editScheme", true ); |
694 | if ( QPEApplication::execDialog( editdlg ) == QDialog::Accepted ) | 694 | if ( QPEApplication::execDialog( editdlg ) == QDialog::Accepted ) |
695 | { | 695 | { |
696 | ColorListItem *citem = (ColorListItem *) m_color_list-> item ( 0 ); | 696 | ColorListItem *citem = (ColorListItem *) m_color_list-> item ( 0 ); |
697 | cnt = 0; | 697 | cnt = 0; |
698 | 698 | ||
699 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) | 699 | for ( int role = 0; role < (int) QColorGroup::NColorRoles; ++role ) |
700 | { | 700 | { |
701 | if ( item-> color ( role ). isValid ( )) | 701 | if ( item->color( static_cast<QColorGroup::ColorRole>( role ) ).isValid() ) |
702 | { | 702 | { |
703 | citem-> setColor ( role, colors [cnt] ); | 703 | citem->setColor( static_cast<QColorGroup::ColorRole>( role ), colors[cnt] ); |
704 | cnt++; | 704 | cnt++; |
705 | } | 705 | } |
706 | } | 706 | } |
707 | 707 | ||
708 | m_color_list-> setCurrentItem ( 0 ); | 708 | m_color_list-> setCurrentItem ( 0 ); |
709 | colorClicked ( 0 ); | 709 | colorClicked ( 0 ); |
710 | 710 | ||
711 | m_color_changed = true; | 711 | m_color_changed = true; |
712 | } | 712 | } |
713 | delete editdlg; | 713 | delete editdlg; |
714 | } | 714 | } |
715 | 715 | ||