Obsolete library/mozjs-60
[oi-userland.git] / components / encumbered / megasync / patches / 15-MegaApplication.cpp.patch
blob9795e3633dbe5f07246d3dca6fcf197cb2a53310
1 --- MEGAsync_ori/src/MEGASync/MegaApplication.cpp Wed Jan 26 20:25:17 2022
2 +++ MEGAsync_patched/src/MEGASync/MegaApplication.cpp Sun Mar 6 01:01:28 2022
3 @@ -22,7 +22,7 @@
5 #include <assert.h>
7 -#ifdef Q_OS_LINUX
8 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
9 #include <signal.h>
10 #include <condition_variable>
11 #include <QSvgRenderer>
12 @@ -54,7 +54,7 @@
14 void MegaApplication::loadDataPath()
16 -#ifdef Q_OS_LINUX
17 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
18 dataPath = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation)
19 + QString::fromUtf8("/data/Mega Limited/MEGAsync");
20 #else
21 @@ -89,7 +89,7 @@
22 args += QString::fromUtf8(argv[i]);
25 -#ifdef Q_OS_LINUX
26 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
28 if (args.contains(QLatin1String("--version")))
30 @@ -418,7 +418,7 @@
31 indexing = false;
32 setQuitOnLastWindowClosed(false);
34 -#ifdef Q_OS_LINUX
35 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
36 isLinux = true;
37 #else
38 isLinux = false;
39 @@ -737,7 +737,7 @@
40 createTrayIcon();
43 -#ifdef Q_OS_LINUX
44 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
45 void MegaApplication::setTrayIconFromTheme(QString icon)
47 QString name = QString(icon).replace(QString::fromUtf8("://images/"), QString::fromUtf8("mega")).replace(QString::fromUtf8(".svg"),QString::fromUtf8(""));
48 @@ -965,7 +965,7 @@
50 void MegaApplication::start()
52 -#ifdef Q_OS_LINUX
53 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
54 QSvgRenderer qsr; //to have svg library linked
55 #endif
57 @@ -2250,7 +2250,7 @@
59 if (trayIcon)
61 -#ifdef Q_OS_LINUX
62 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
63 if (counter==4 && getenv("XDG_CURRENT_DESKTOP") && !strcmp(getenv("XDG_CURRENT_DESKTOP"),"XFCE"))
65 trayIcon->hide();
66 @@ -5793,7 +5793,7 @@
67 whyAmIBlocked();
70 -#ifdef Q_OS_LINUX
71 +#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS)
72 if (getenv("XDG_CURRENT_DESKTOP") && (
73 !strcmp(getenv("XDG_CURRENT_DESKTOP"),"ubuntu:GNOME")
74 || !strcmp(getenv("XDG_CURRENT_DESKTOP"),"LXDE")