Ticket #4231: ScreenAppApplyButton.patch

File ScreenAppApplyButton.patch, 782 bytes (added by ScottyBeGSOC, 8 years ago)

Patch to fix problem of apply button always enabled.

  • src/preferences/screen/ScreenWindow.cpp

    diff --git a/src/preferences/screen/ScreenWindow.cpp b/src/preferences/screen/ScreenWindow.cpp
    index be99486..0c4f543 100644
    a b ScreenWindow::_BuildSupportedColorSpaces()  
    11521152
    11531153void
    11541154ScreenWindow::_CheckApplyEnabled()
    1155 {
    1156     fApplyButton->SetEnabled(fSelected != fActive
    1157         || fAllWorkspacesItem->IsMarked());
    1158 
     1155{   
    11591156    uint32 columns;
    11601157    uint32 rows;
    11611158    BPrivate::get_workspaces_layout(&columns, &rows);
    11621159
     1160    fApplyButton->SetEnabled(columns != fOriginalWorkspacesColumns
     1161        || rows != fOriginalWorkspacesRows
     1162        || fSelected != fOriginal);
     1163
    11631164    fRevertButton->SetEnabled(columns != fOriginalWorkspacesColumns
    11641165        || rows != fOriginalWorkspacesRows
    11651166        || fSelected != fOriginal);