mirror of https://github.com/procxx/kepka.git
fixed unity count, version 0.8.41.dev
This commit is contained in:
parent
8339c51017
commit
f0c580db2d
|
@ -43,7 +43,7 @@ namespace {
|
||||||
}
|
}
|
||||||
|
|
||||||
FlatInput::FlatInput(QWidget *parent, const style::flatInput &st, const QString &pholder, const QString &v) : QLineEdit(v, parent),
|
FlatInput::FlatInput(QWidget *parent, const style::flatInput &st, const QString &pholder, const QString &v) : QLineEdit(v, parent),
|
||||||
_fullph(pholder), _fastph(false), _oldtext(v), _kev(0), _customUpDown(false), _phVisible(!v.length()),
|
_fullph(pholder), _oldtext(v), _fastph(false), _kev(0), _customUpDown(false), _phVisible(!v.length()),
|
||||||
a_phLeft(_phVisible ? 0 : st.phShift), a_phAlpha(_phVisible ? 1 : 0), a_phColor(st.phColor->c),
|
a_phLeft(_phVisible ? 0 : st.phShift), a_phAlpha(_phVisible ? 1 : 0), a_phColor(st.phColor->c),
|
||||||
a_borderColor(st.borderColor->c), a_bgColor(st.bgColor->c), _notingBene(0), _st(st) {
|
a_borderColor(st.borderColor->c), a_bgColor(st.bgColor->c), _notingBene(0), _st(st) {
|
||||||
resize(_st.width, _st.height);
|
resize(_st.width, _st.height);
|
||||||
|
|
|
@ -415,9 +415,24 @@ namespace {
|
||||||
}
|
}
|
||||||
|
|
||||||
void setupGtk() {
|
void setupGtk() {
|
||||||
if (!noQtTrayIcon) return;
|
|
||||||
|
|
||||||
QLibrary lib_gtk, lib_indicator;
|
QLibrary lib_gtk, lib_indicator;
|
||||||
|
if (!noQtTrayIcon) {
|
||||||
|
if (!noTryUnity) {
|
||||||
|
if (loadLibrary(lib_gtk, "gtk-3", 0)) {
|
||||||
|
setupGtkBase(lib_gtk);
|
||||||
|
}
|
||||||
|
if (!useGtkBase) {
|
||||||
|
if (loadLibrary(lib_gtk, "gtk-x11-2.0", 0)) {
|
||||||
|
setupGtkBase(lib_gtk);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!useGtkBase) {
|
||||||
|
noTryUnity = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (loadLibrary(lib_indicator, "appindicator3", 1)) {
|
if (loadLibrary(lib_indicator, "appindicator3", 1)) {
|
||||||
if (loadLibrary(lib_gtk, "gtk-3", 0)) {
|
if (loadLibrary(lib_gtk, "gtk-3", 0)) {
|
||||||
setupGtkBase(lib_gtk);
|
setupGtkBase(lib_gtk);
|
||||||
|
@ -745,6 +760,14 @@ void PsMainWindow::psUpdatedPosition() {
|
||||||
void PsMainWindow::psCreateTrayIcon() {
|
void PsMainWindow::psCreateTrayIcon() {
|
||||||
if (!noQtTrayIcon) {
|
if (!noQtTrayIcon) {
|
||||||
cSetSupportTray(QSystemTrayIcon::isSystemTrayAvailable());
|
cSetSupportTray(QSystemTrayIcon::isSystemTrayAvailable());
|
||||||
|
if (!noTryUnity) {
|
||||||
|
if (ps_gtk_init_check(0, 0)) {
|
||||||
|
DEBUG_LOG(("Checked gtk with gtk_init_check!"));
|
||||||
|
} else {
|
||||||
|
DEBUG_LOG(("Failed to gtk_init_check(0, 0)!"));
|
||||||
|
useUnityCount = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue