Merge lp:~ralsina/ubuntu-sso-client/cross-platform into lp:ubuntu-sso-client

Proposed by Roberto Alsina
Status: Merged
Approved by: Natalia Bidart
Approved revision: 915
Merged at revision: 915
Proposed branch: lp:~ralsina/ubuntu-sso-client/cross-platform
Merge into: lp:ubuntu-sso-client
Diff against target: 26 lines (+6/-3)
1 file modified
bin/ubuntu-sso-login-qt (+6/-3)
To merge this branch: bzr merge lp:~ralsina/ubuntu-sso-client/cross-platform
Reviewer Review Type Date Requested Status
Natalia Bidart (community) Approve
Diego Sarmentero (community) Approve
Review via email: mp+97746@code.launchpad.net

Commit message

 - Only import DBus on Linux (LP: #956304).

Description of the change

 - Only import DBus on Linux (LP: #956304).

To post a comment you must log in.
Revision history for this message
Diego Sarmentero (diegosarmentero) wrote :

+1

review: Approve
915. By Roberto Alsina

fix lint

Revision history for this message
Natalia Bidart (nataliabidart) wrote :

Looks good!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'bin/ubuntu-sso-login-qt'
2--- bin/ubuntu-sso-login-qt 2012-02-13 15:43:59 +0000
3+++ bin/ubuntu-sso-login-qt 2012-03-15 20:20:42 +0000
4@@ -15,16 +15,19 @@
5 # You should have received a copy of the GNU General Public License along
6 # with this program. If not, see <http://www.gnu.org/licenses/>.
7
8-"""Start the sso GTK UI."""
9+"""Start the sso Qt UI."""
10
11 # Invalid name "ubuntu-sso-login-qt", pylint: disable=C0103
12 # Access to a protected member, pylint: disable=W0212
13
14+import sys
15+
16 from ubuntu_sso.qt.main import main
17 from ubuntu_sso.utils.ui import parse_args
18
19-from dbus.mainloop.qt import DBusQtMainLoop
20-DBusQtMainLoop(set_as_default=True)
21+if sys.platform.startswith('linux'):
22+ from dbus.mainloop.qt import DBusQtMainLoop
23+ DBusQtMainLoop(set_as_default=True)
24
25
26 if __name__ == "__main__":

Subscribers

People subscribed via source and target branches