r19608 by craig - #12785: Remove auto message box button swapping code
scribus-commit
scribus-commit at lists.scribus.net
Wed Oct 22 18:33:38 UTC 2014
Author: craig
Date: Wed Oct 22 18:33:38 2014
New Revision: 19608
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=19608
Log:
#12785: Remove auto message box button swapping code
Modified:
trunk/Scribus/scribus/plugins/scriptplugin/scripter2/scripter2_scribus_scribusqapp.cpp
trunk/Scribus/scribus/scribusapp.cpp
trunk/Scribus/scribus/scribusapp.h
trunk/Scribus/scribus/scribuscore.cpp
trunk/Scribus/scribus/scribuscore.h
Modified: trunk/Scribus/scribus/plugins/scriptplugin/scripter2/scripter2_scribus_scribusqapp.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19608&path=/trunk/Scribus/scribus/plugins/scriptplugin/scripter2/scripter2_scribus_scribusqapp.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/scripter2/scripter2_scribus_scribusqapp.cpp (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/scripter2/scripter2_scribus_scribusqapp.cpp Wed Oct 22 18:33:38 2014
@@ -20,8 +20,7 @@
"The core application",
no_init)
.add_property("usingGUI", &ScribusQApp::usingGUI)
- .add_property("isMacGUI", &ScribusQApp::isMacGUI)
- .add_property("reverseDialogButtons", &ScribusQApp::reverseDialogButtons);
+ .add_property("isMacGUI", &ScribusQApp::isMacGUI);
scope().attr("ScQApp") = boost::ref(ScQApp);
}
Modified: trunk/Scribus/scribus/scribusapp.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19608&path=/trunk/Scribus/scribus/scribusapp.cpp
==============================================================================
--- trunk/Scribus/scribus/scribusapp.cpp (original)
+++ trunk/Scribus/scribus/scribusapp.cpp Wed Oct 22 18:33:38 2014
@@ -62,7 +62,6 @@
#define ARG_DISPLAY "--display"
#define ARG_FONTINFO "--font-info"
#define ARG_PROFILEINFO "--profile-info"
-#define ARG_SWAPDIABUTTONS "--swap-buttons"
#define ARG_PREFS "--prefs"
#define ARG_UPGRADECHECK "--upgradecheck"
#define ARG_TESTS "--tests"
@@ -78,7 +77,6 @@
#define ARG_DISPLAY_SHORT "-d"
#define ARG_FONTINFO_SHORT "-fi"
#define ARG_PROFILEINFO_SHORT "-pi"
-#define ARG_SWAPDIABUTTONS_SHORT "-sb"
#define ARG_PREFS_SHORT "-pr"
#define ARG_UPGRADECHECK_SHORT "-u"
#define ARG_TESTS_SHORT "-T"
@@ -148,7 +146,6 @@
#endif
showFontInfo=false;
showProfileInfo=false;
- swapDialogButtonOrder=false;
//Parse for command line information options, and lang
// Qt5 port: do this in a Qt compatible manner
@@ -229,8 +226,6 @@
showFontInfo=true;
} else if (arg == ARG_PROFILEINFO || arg == ARG_PROFILEINFO_SHORT) {
showProfileInfo=true;
- } else if (arg == ARG_SWAPDIABUTTONS || arg == ARG_SWAPDIABUTTONS_SHORT) {
- swapDialogButtonOrder=true;
} else if ((arg == ARG_DISPLAY || arg==ARG_DISPLAY_SHORT || arg==ARG_DISPLAY_QT) && ++i < argsc) {
// allow setting of display, QT expect the option -display <display_name> so we discard the
// last argument. FIXME: Qt only understands -display not --display and -d , we need to work
@@ -294,7 +289,7 @@
return EXIT_FAILURE;
ScCore=m_ScCore;
processEvents();
- ScCore->init(useGUI, swapDialogButtonOrder, filesToLoad);
+ ScCore->init(useGUI, filesToLoad);
int retVal=EXIT_SUCCESS;
/* TODO:
* When Scribus is truly able to run without GUI
@@ -486,7 +481,6 @@
printArgLine(ts, ARG_NEVERSPLASH_SHORT, ARG_NEVERSPLASH, tr("Stop the showing of the splashscreen on startup. Writes an empty file called .neversplash in ~/.scribus.") );
printArgLine(ts, ARG_PREFS_SHORT, QString(QString(ARG_PREFS) + QString(" ") + tr("filename")).toLocal8Bit().constData(), tr("Use filename as path for user given preferences") );
printArgLine(ts, ARG_PROFILEINFO_SHORT, ARG_PROFILEINFO, tr("Show location ICC profile information on console while starting") );
- printArgLine(ts, ARG_SWAPDIABUTTONS_SHORT, ARG_SWAPDIABUTTONS, tr("Use right to left dialog button ordering (eg. Cancel/No/Yes instead of Yes/No/Cancel)") );
printArgLine(ts, ARG_UPGRADECHECK_SHORT, ARG_UPGRADECHECK, tr("Download a file from the Scribus website and show the latest available version.") );
printArgLine(ts, ARG_VERSION_SHORT, ARG_VERSION, tr("Output version information and exit") );
printArgLine(ts, ARG_PYTHONSCRIPT_SHORT, QString(QString(ARG_PYTHONSCRIPT) + QString(" ") + tr("filename")).toLocal8Bit().constData(), tr("Run filename in Python scripter") );
Modified: trunk/Scribus/scribus/scribusapp.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19608&path=/trunk/Scribus/scribus/scribusapp.h
==============================================================================
--- trunk/Scribus/scribus/scribusapp.h (original)
+++ trunk/Scribus/scribus/scribusapp.h Wed Oct 22 18:33:38 2014
@@ -94,7 +94,6 @@
bool showSplash;
bool showFontInfo;
bool showProfileInfo;
- bool swapDialogButtonOrder;
//! \brief If is there user given prefs file...
QString prefsUserFile;
QList<QString> filesToLoad;
Modified: trunk/Scribus/scribus/scribuscore.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19608&path=/trunk/Scribus/scribus/scribuscore.cpp
==============================================================================
--- trunk/Scribus/scribus/scribuscore.cpp (original)
+++ trunk/Scribus/scribus/scribuscore.cpp Wed Oct 22 18:33:38 2014
@@ -82,11 +82,10 @@
#endif
-int ScribusCore::init(bool useGUI, bool swapDialogButtonOrder, const QList<QString>& filesToUse)
+int ScribusCore::init(bool useGUI, const QList<QString>& filesToUse)
{
m_UseGUI=useGUI;
m_Files=filesToUse;
- m_SwapDialogButtonOrder=swapDialogButtonOrder;
#if !defined(NDEBUG) && !defined(_WIN32)
qInstallMsgHandler( & abort_on_error );
#endif
@@ -287,31 +286,6 @@
#endif
}
-bool ScribusCore::reverseDialogButtons() const
-{
- if (m_SwapDialogButtonOrder)
- return true;
- //Win32 - dont switch
- #if defined(_WIN32)
- return false;
- //Mac Aqua - switch
- #elif defined(Q_OS_MAC)
- return true;
- #else
- //Gnome - switch
- QString gnomesession= ::getenv("GNOME_DESKTOP_SESSION_ID");
- if (!gnomesession.isEmpty())
- return true;
-
- //KDE/KDE Aqua - dont switch
- //Best guess for now if we are running under KDE
- QString kdesession= ::getenv("KDE_FULL_SESSION");
- if (!kdesession.isEmpty())
- return false;
- #endif
- return false;
-}
-
//Returns false when there are no fonts
bool ScribusCore::initFonts(bool showFontInfo)
{
Modified: trunk/Scribus/scribus/scribuscore.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=19608&path=/trunk/Scribus/scribus/scribuscore.h
==============================================================================
--- trunk/Scribus/scribus/scribuscore.h (original)
+++ trunk/Scribus/scribus/scribuscore.h Wed Oct 22 18:33:38 2014
@@ -63,7 +63,7 @@
int exportToSVG() {return 0;}
int runScript() {return 0;}
*/
- int init(bool useGUI, bool swapDialogButtonOrder, const QList<QString>& filesToUse);
+ int init(bool useGUI, const QList<QString>& filesToUse);
int initScribusCore(bool showSplash, bool showFontInfo, bool showProfileInfo, const QString newGuiLanguage, const QString prefsUserFile);
bool initialized() const {return m_ScribusInitialized;};
const QString& getGuiLanguage() const;
@@ -85,11 +85,6 @@
* @retval bool true if we are on Qt/Win
*/
bool isWinGUI() const;
- /**
- * @brief Are we swapping dialog button order?
- * @retval bool if we are swapping
- */
- bool reverseDialogButtons() const;
bool haveCMS() const {return m_HaveCMS;}
bool haveGS() const {return m_HaveGS;};
bool havePNGAlpha() const {return m_HavePngAlpha;}
@@ -136,7 +131,6 @@
PrefsManager *prefsManager;
bool m_ScribusInitialized;
bool m_UseGUI;
- bool m_SwapDialogButtonOrder;
QList<QString> m_Files;
bool m_HaveCMS;
bool m_HaveGS;
More information about the scribus-commit
mailing list