Ticket #4853: mythtv-4853-StyleSetting_default.patch

File mythtv-4853-StyleSetting_default.patch, 1.3 KB (added by sphery <mtdean@…>, 13 years ago)

Updated patch for post-Qt4 trunk

  • programs/mythfrontend/globalsettings.cpp

     
    28602860
    28612861    void fillSelections(void) {
    28622862        clearSelections();
    2863         addSelection(QObject::tr("Desktop Style"), "");
     2863        addSelection(QObject::tr("Desktop Style"),
     2864                     "UseSystemDefaultDesktopStyle");
    28642865        QStyleFactory factory;
    28652866        QStringList list = factory.keys();
    28662867        QStringList::iterator iter = list.begin();
  • libs/libmyth/mythcontext.cpp

     
    77#include <qfileinfo.h>
    88#include <qdesktopwidget.h>
    99#include <qpainter.h>
     10#include <QStyleFactory>
    1011
    1112#include <cmath>
    1213#include <queue>
     
    20182019
    20192020    d->m_qtThemeSettings = new Settings;
    20202021
    2021     QString style = GetSetting("Style", "");
    2022     if (style != "")
     2022    QString style = GetSetting("Style", "UseSystemDefaultDesktopStyle");
     2023    if (QStyleFactory::keys().contains(style))
    20232024        qApp->setStyle(style);
    20242025
    20252026    QString themename = GetSetting("Theme");