Skip to content

Commit

Permalink
[ssu] Get proxy configuration from connman
Browse files Browse the repository at this point in the history
  • Loading branch information
martyone committed Nov 7, 2013
1 parent b48fad8 commit 37300dc
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 6 deletions.
4 changes: 2 additions & 2 deletions rndssucli/main.cpp
Expand Up @@ -10,7 +10,7 @@
#include <QLocale>
#include <QLibraryInfo>
#include <QTimer>
#include <QNetworkProxyFactory>
#include <connman-qt5/connmannetworkproxyfactory.h>
#include "rndssucli.h"

int main(int argc, char** argv){
Expand All @@ -24,7 +24,7 @@ int main(int argc, char** argv){
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
app.installTranslator(&qtTranslator);

QNetworkProxyFactory::setUseSystemConfiguration(true);
QNetworkProxyFactory::setApplicationProxyFactory(new ConnmanNetworkProxyFactory);

RndSsuCli mw;
QTimer::singleShot(0, &mw, SLOT(run()));
Expand Down
2 changes: 2 additions & 0 deletions rndssucli/rndssucli.pro
Expand Up @@ -3,6 +3,8 @@ include(../ssuapplication.pri)
include(rndssucli_dependencies.pri)

QT += network dbus
CONFIG += link_pkgconfig
PKGCONFIG += connman-qt5

HEADERS = rndssucli.h \
ssuproxy.h
Expand Down
1 change: 1 addition & 0 deletions rpm/ssu.spec
Expand Up @@ -16,6 +16,7 @@ BuildRequires: pkgconfig(Qt5SystemInfo)
BuildRequires: pkgconfig(libzypp)
BuildRequires: pkgconfig(libsystemd-journal)
BuildRequires: pkgconfig(libshadowutils)
BuildRequires: pkgconfig(connman-qt5)
BuildRequires: oneshot
BuildRequires: doxygen
Requires(pre): shadow-utils
Expand Down
4 changes: 2 additions & 2 deletions ssud/main.cpp
Expand Up @@ -9,7 +9,7 @@
#include <QTranslator>
#include <QLocale>
#include <QLibraryInfo>
#include <QNetworkProxyFactory>
#include <connman-qt5/connmannetworkproxyfactory.h>
#include "ssud.h"

int main(int argc, char** argv){
Expand All @@ -23,7 +23,7 @@ int main(int argc, char** argv){
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
app.installTranslator(&qtTranslator);

QNetworkProxyFactory::setUseSystemConfiguration(true);
QNetworkProxyFactory::setApplicationProxyFactory(new ConnmanNetworkProxyFactory);

Ssud ssud;

Expand Down
2 changes: 2 additions & 0 deletions ssud/ssud.pro
Expand Up @@ -3,6 +3,8 @@ include(../ssuapplication.pri)
include(ssud_dependencies.pri)

QT += network dbus
CONFIG += link_pkgconfig
PKGCONFIG += connman-qt5

HEADERS = ssuadaptor.h \
ssud.h
Expand Down
4 changes: 2 additions & 2 deletions ssuurlresolver/main.cpp
Expand Up @@ -10,7 +10,7 @@
#include <QLocale>
#include <QLibraryInfo>
#include <QTimer>
#include <QNetworkProxyFactory>
#include <connman-qt5/connmannetworkproxyfactory.h>
#include "ssuurlresolver.h"

int main(int argc, char** argv){
Expand All @@ -24,7 +24,7 @@ int main(int argc, char** argv){
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
app.installTranslator(&qtTranslator);

QNetworkProxyFactory::setUseSystemConfiguration(true);
QNetworkProxyFactory::setApplicationProxyFactory(new ConnmanNetworkProxyFactory);

SsuUrlResolver mw;
QTimer::singleShot(0, &mw, SLOT(run()));
Expand Down
2 changes: 2 additions & 0 deletions ssuurlresolver/ssuurlresolver.pro
Expand Up @@ -7,6 +7,8 @@ DESTDIR = $$DESTDIR_LIB/zypp/plugins/urlresolver
target.path = /usr/lib/zypp/plugins/urlresolver

QT += network
CONFIG += link_pkgconfig
PKGCONFIG += connman-qt5

HEADERS = ssuurlresolver.h
SOURCES = main.cpp \
Expand Down

0 comments on commit 37300dc

Please sign in to comment.