mirror of
https://invent.kde.org/network/falkon.git
synced 2024-11-11 09:32:12 +01:00
Using resources inside bundle on Mac. Hopefully closes #125
- also improved mac .plist a little
This commit is contained in:
parent
e39ddf5a79
commit
c35aceaa1a
|
@ -15,6 +15,28 @@
|
|||
<key>CFBundleIdentifier</key>
|
||||
<string>com.qupzilla.QupZilla</string>
|
||||
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>html</string>
|
||||
<string>htm</string>
|
||||
<string>shtml</string>
|
||||
<string>xhtml</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>@ICON@</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>HTML Document</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>HTML</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
</dict>
|
||||
</array>
|
||||
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
<key>CFBundleName</key>
|
||||
|
@ -23,6 +45,6 @@
|
|||
<string>QupZilla</string>
|
||||
|
||||
<key>NOTE</key>
|
||||
<string>This file was generated by Qt/QMake.</string>
|
||||
<string>QupZilla Web Browser</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
|
|
@ -47,10 +47,20 @@
|
|||
|
||||
#ifdef Q_WS_WIN
|
||||
#define DEFAULT_CHECK_UPDATES true
|
||||
#define DEFAULT_THEME_NAME "windows"
|
||||
#else
|
||||
#define DEFAULT_CHECK_UPDATES false
|
||||
#endif
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#define DEFAULT_THEME_NAME "windows"
|
||||
#elif defined(Q_WS_X11)
|
||||
#define DEFAULT_THEME_NAME "linux"
|
||||
#elif defined(Q_WS_MAC)
|
||||
#define DEFAULT_THEME_NAME "mac"
|
||||
#elif defined(Q_OS_OS2)
|
||||
#define DEFAULT_THEME_NAME "windows"
|
||||
#else
|
||||
#define DEFAULT_THEME_NAME "default"
|
||||
#endif
|
||||
|
||||
#if defined(PORTABLE_BUILD) && !defined(NO_SYSTEM_DATAPATH)
|
||||
|
@ -82,12 +92,16 @@ MainApplication::MainApplication(const QList<CommandLineOptions::ActionPair> &cm
|
|||
, m_isRestoring(false)
|
||||
, m_databaseConnected(false)
|
||||
{
|
||||
#if defined(Q_WS_X11) & !defined(NO_SYSTEM_DATAPATH)
|
||||
#if defined(Q_WS_X11) && !defined(NO_SYSTEM_DATAPATH)
|
||||
DATADIR = USE_DATADIR;
|
||||
#else
|
||||
DATADIR = qApp->applicationDirPath() + "/";
|
||||
#endif
|
||||
|
||||
#ifdef Q_WS_MAC
|
||||
DATADIR.append("Resources/");
|
||||
#endif
|
||||
|
||||
#ifdef PORTABLE_BUILD
|
||||
PROFILEDIR = DATADIR + "profiles/";
|
||||
#else
|
||||
|
@ -561,7 +575,7 @@ void MainApplication::quitApplication()
|
|||
// everything gets saved also when quitting application in other
|
||||
// way than clicking Quit action in File menu or closing last window
|
||||
//
|
||||
// * this can occur on Mac OS
|
||||
// * this can occur on Mac OS (see #157)
|
||||
|
||||
quit();
|
||||
}
|
||||
|
|
|
@ -377,6 +377,13 @@ win32 {
|
|||
mac {
|
||||
QMAKE_INFO_PLIST = Info.plist
|
||||
ICON = data/icons/exeicons/qupzilla.icns
|
||||
|
||||
bundle_target.files += ../bin/locale
|
||||
bundle_target.files += ../bin/plugins
|
||||
bundle_target.files += ../bin/themes
|
||||
bundle_target.path = Resources
|
||||
|
||||
QMAKE_BUNDLE_DATA += bundle_target
|
||||
}
|
||||
|
||||
unix {
|
||||
|
|
Loading…
Reference in New Issue
Block a user