Install a separate Private Browsing desktop file
This way private browsing can be added as a shortcut and typing in Synapse, Unity or GNOME Shell suggests it.
This commit is contained in:
parent
6da6b133f5
commit
54251cc368
2 changed files with 18 additions and 4 deletions
13
data/midori-private.desktop.in
Normal file
13
data/midori-private.desktop.in
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
[Desktop Entry]
|
||||||
|
Version=1.0
|
||||||
|
Type=Application
|
||||||
|
_Name=Private Browsing
|
||||||
|
_Comment=Open a new private browsing window
|
||||||
|
Categories=GTK;Network;WebBrowser;
|
||||||
|
Exec=midori --private
|
||||||
|
Icon=midori
|
||||||
|
Terminal=false
|
||||||
|
StartupNotify=true
|
||||||
|
X-Osso-Type=application/x-executable
|
||||||
|
X-Osso-Service=midori
|
||||||
|
|
9
wscript
9
wscript
|
@ -412,7 +412,9 @@ def build (bld):
|
||||||
bld.add_subdirs ('docs/api')
|
bld.add_subdirs ('docs/api')
|
||||||
bld.install_files ('${DOCDIR}/api/', blddir + '/docs/api/*')
|
bld.install_files ('${DOCDIR}/api/', blddir + '/docs/api/*')
|
||||||
|
|
||||||
if not is_mingw (bld.env) and Options.platform != 'win32':
|
for desktop in [APPNAME + '.desktop', APPNAME + '-private.desktop']:
|
||||||
|
if is_mingw (bld.env) or Options.platform == 'win32':
|
||||||
|
break
|
||||||
if bld.env['HAVE_HILDON']:
|
if bld.env['HAVE_HILDON']:
|
||||||
appdir = '${MDATADIR}/applications/hildon'
|
appdir = '${MDATADIR}/applications/hildon'
|
||||||
bld.install_files ('${MDATADIR}/dbus-1/services',
|
bld.install_files ('${MDATADIR}/dbus-1/services',
|
||||||
|
@ -421,14 +423,13 @@ def build (bld):
|
||||||
appdir = '${MDATADIR}/applications'
|
appdir = '${MDATADIR}/applications'
|
||||||
if bld.env['INTLTOOL']:
|
if bld.env['INTLTOOL']:
|
||||||
obj = bld.new_task_gen ('intltool_in')
|
obj = bld.new_task_gen ('intltool_in')
|
||||||
obj.source = 'data/' + APPNAME + '.desktop.in'
|
obj.source = 'data/' + desktop + '.in'
|
||||||
obj.install_path = appdir
|
obj.install_path = appdir
|
||||||
obj.flags = ['-d', '-c']
|
obj.flags = ['-d', '-c']
|
||||||
bld.install_files (appdir, 'data/' + APPNAME + '.desktop')
|
bld.install_files (appdir, 'data/' + desktop)
|
||||||
else:
|
else:
|
||||||
folder = os.path.abspath (blddir + '/default/data')
|
folder = os.path.abspath (blddir + '/default/data')
|
||||||
Utils.check_dir (folder)
|
Utils.check_dir (folder)
|
||||||
desktop = APPNAME + '.desktop'
|
|
||||||
pre = open ('data/' + desktop + '.in')
|
pre = open ('data/' + desktop + '.in')
|
||||||
after = open (folder + '/' + desktop, 'w')
|
after = open (folder + '/' + desktop, 'w')
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue