Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 206792 | Differences between
and this patch

Collapse All | Expand All

(-)src/mumble/main.cpp (-24 lines)
Lines 39-45 Link Here
39
#include "Plugins.h"
39
#include "Plugins.h"
40
#include "Global.h"
40
#include "Global.h"
41
#ifndef Q_OS_MAC
41
#ifndef Q_OS_MAC
42
#include "DBus.h"
43
#endif
42
#endif
44
#include "VersionCheck.h"
43
#include "VersionCheck.h"
45
#include "NetworkConfig.h"
44
#include "NetworkConfig.h"
Lines 73-95 Link Here
73
72
74
	Global::g_global_struct = new Global();
73
	Global::g_global_struct = new Global();
75
74
76
#ifndef Q_OS_MAC
77
#ifdef Q_OS_WIN
78
	// By default, windbus expects the path to dbus-daemon to be in PATH, and the path
79
	// should contain bin\\, and the path to the config is hardcoded as ..\etc
80
	_putenv(qPrintable(QString::fromLatin1("PATH=%1\\bin;%1;%2").arg(QDir::toNativeSeparators(a.applicationDirPath())).arg(QLatin1String(getenv("PATH")))));
81
#endif
82
83
	QDBusInterface qdbi(QLatin1String("net.sourceforge.mumble.mumble"), QLatin1String("/"));
84
	QDBusMessage reply=qdbi.call(QLatin1String("focus"));
85
	if (reply.type() == QDBusMessage::ReplyMessage) {
86
		if (a.arguments().count() > 1) {
87
			qdbi.call(QLatin1String("openUrl"), a.arguments().last());
88
		}
89
		return 0;
90
	}
91
#endif
92
93
	QFile inifile(QString::fromLatin1("%1/mumble.ini").arg(a.applicationDirPath()));
75
	QFile inifile(QString::fromLatin1("%1/mumble.ini").arg(a.applicationDirPath()));
94
	if (inifile.exists() && inifile.permissions().testFlag(QFile::WriteUser))
76
	if (inifile.exists() && inifile.permissions().testFlag(QFile::WriteUser))
95
		g.qs = new QSettings(inifile.fileName(), QSettings::IniFormat);
77
		g.qs = new QSettings(inifile.fileName(), QSettings::IniFormat);
Lines 166-177 Link Here
166
	g.mw=new MainWindow(NULL);
148
	g.mw=new MainWindow(NULL);
167
	g.mw->show();
149
	g.mw->show();
168
150
169
#ifndef Q_OS_MAC
170
	new MumbleDBus(g.mw);
171
	QDBusConnection::sessionBus().registerObject("/", g.mw);
172
	QDBusConnection::sessionBus().registerService("net.sourceforge.mumble.mumble");
173
#endif
174
175
	g.l->log(Log::Information, MainWindow::tr("Welcome to Mumble."));
151
	g.l->log(Log::Information, MainWindow::tr("Welcome to Mumble."));
176
152
177
	// Plugins
153
	// Plugins
(-)src/mumble/mumble.pro (-6 lines)
Lines 18-29 Link Here
18
18
19
QMAKE_CXXFLAGS	+= -Wall -Wextra
19
QMAKE_CXXFLAGS	+= -Wall -Wextra
20
20
21
!macx {
22
  CONFIG                += qdbus
23
  HEADERS               += DBus.h
24
  SOURCES               += DBus.cpp
25
}
26
27
win32 {
21
win32 {
28
  RC_FILE	= mumble.rc
22
  RC_FILE	= mumble.rc
29
  HEADERS	+= DXAudioInput.h DXAudioOutput.h DXConfigDialog.h GlobalShortcut_win.h
23
  HEADERS	+= DXAudioInput.h DXAudioOutput.h DXConfigDialog.h GlobalShortcut_win.h
(-)src/mumble/mumble_pch.hpp (-1 lines)
Lines 4-10 Link Here
4
#define QT_ASCII_CAST_WARNINGS
4
#define QT_ASCII_CAST_WARNINGS
5
#define QT_NO_CAST_TO_ASCII
5
#define QT_NO_CAST_TO_ASCII
6
#include <QtCore/QtCore>
6
#include <QtCore/QtCore>
7
#include <QtDBus/QtDBus>
8
#include <QtGui/QtGui>
7
#include <QtGui/QtGui>
9
#include <QtNetwork/QtNetwork>
8
#include <QtNetwork/QtNetwork>
10
#include <QtOpenGL/QtOpenGL>
9
#include <QtOpenGL/QtOpenGL>

Return to bug 206792