~ubuntu-branches/ubuntu/saucy/unity-tweak-tool/saucy-proposed

« back to all changes in this revision

Viewing changes to unity-tweak-tool

  • Committer: Package Import Robot
  • Author(s): Barneedhar Vigneshwar
  • Date: 2013-02-15 20:33:41 UTC
  • Revision ID: package-import@ubuntu.com-20130215203341-yqrfr9df488k41am
Tags: 0.0.3
* New upstream release
* Closes needs-packaging bug (LP: #1126433)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/env python3
 
2
# -*- coding: utf-8 -*-
 
3
#
 
4
# Team:
 
5
#   J Phani Mahesh <phanimahesh@gmail.com>
 
6
#   Barneedhar (jokerdino) <barneedhar@ubuntu.com>
 
7
#   Amith KK <amithkumaran@gmail.com>
 
8
#   Georgi Karavasilev <motorslav@gmail.com>
 
9
#   Sam Tran <samvtran@gmail.com>
 
10
#   Sam Hewitt <hewittsamuel@gmail.com>
 
11
#   Angel Araya <al.arayaq@gmail.com>
 
12
#
 
13
# Description:
 
14
#   A One-stop configuration tool for Unity.
 
15
#
 
16
# Legal Stuff:
 
17
#
 
18
# This file is a part of Unity Tweak Tool
 
19
#
 
20
# Unity Tweak Tool is free software; you can redistribute it and/or modify it under
 
21
# the terms of the GNU General Public License as published by the Free Software
 
22
# Foundation; version 3.
 
23
#
 
24
# Unity Tweak Tool is distributed in the hope that it will be useful, but WITHOUT
 
25
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 
26
# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
 
27
# details.
 
28
#
 
29
# You should have received a copy of the GNU General Public License along with
 
30
# this program; if not, see <https://www.gnu.org/licenses/gpl-3.0.txt>
 
31
 
 
32
import argparse
 
33
import UnityTweakTool
 
34
 
 
35
parser = argparse.ArgumentParser()
 
36
optgrp = parser.add_mutually_exclusive_group()
 
37
 
 
38
optgrp.add_argument('-u', '--unity', help='Start in the Unity tab', action='store_true')
 
39
optgrp.add_argument('-w', '--winmng', help='Start in the WindowManager tab', action='store_true')
 
40
optgrp.add_argument('-a', '--appearance', help='Start in the appearance tab', action='store_true')
 
41
optgrp.add_argument('-s', '--system', help='Start in the system tab', action='store_true')
 
42
optgrp.add_argument('-r', '--restore', help='Restore settings to its default values', action='store_true')
 
43
 
 
44
args=parser.parse_args()
 
45
 
 
46
if args.unity:
 
47
    UnityTweakTool.init(1)
 
48
elif args.winmng:
 
49
    UnityTweakTool.init(2)
 
50
elif args.appearance:
 
51
    UnityTweakTool.init(3)
 
52
elif args.system:
 
53
    UnityTweakTool.init(4)
 
54
elif args.restore:
 
55
    UnityTweakTool.reset_all()
 
56
else:
 
57
    UnityTweakTool.init()