Esempio n. 1
0
	def activate(self, leaf):
		email = email_from_leaf(leaf)

		if not utils.spawn_async(['thunderbird', 'mailto:%s' % email]):
			utils.spawn_async(['icedove', 'mailto:%s' % email])
		if (not utils.spawn_async_notify_as(
		        'thunderbird.desktop', ['thunderbird', 'mailto:%s' % email])):
			utils.spawn_async_notify_as(
					'icedove.desktop', ['icedove', 'mailto:%s' % email])
Esempio n. 2
0
 def activate(self, leaf):
     text = leaf.object
     dict_id = __kupfer_settings__["dictionary"]
     dict_argv = list(dictionaries[dict_id])
     dict_argv[-1] = dict_argv[-1] + kupferstring.tolocale(text)
     try:
         utils.spawn_async_notify_as(dict_id + ".desktop", dict_argv)
     except utils.SpawnError as exc:
         raise OperationError(exc)
Esempio n. 3
0
	def _make_archive(cls, ctx, basename, dirpath, filepaths):
		archive_type = __kupfer_settings__["archive_type"]
		archive_path = \
			utils.get_destpath_in_directory(dirpath, basename, archive_type)
		cmd = ["file-roller", "--add-to=%s" % (archive_path, )]
		cmd.extend(filepaths)
		runtimehelper.register_async_file_result(ctx, archive_path)
		utils.spawn_async_notify_as("file-roller.desktop", cmd)
		return archive_path
Esempio n. 4
0
 def _make_archive(cls, ctx, basename, dirpath, filepaths):
     archive_type = __kupfer_settings__["archive_type"]
     archive_path = \
         utils.get_destpath_in_directory(dirpath, basename, archive_type)
     cmd = ["file-roller", "--add-to=%s" % (archive_path, )]
     cmd.extend(filepaths)
     runtimehelper.register_async_file_result(ctx, archive_path)
     utils.spawn_async_notify_as("file-roller.desktop", cmd)
     return archive_path
Esempio n. 5
0
 def activate(self, leaf):
     text = leaf.object
     dict_id = __kupfer_settings__["dictionary"]
     dict_argv = list(dictionaries[dict_id])
     dict_argv[-1] = dict_argv[-1] + text
     try:
         utils.spawn_async_notify_as(dict_id + ".desktop", dict_argv)
     except utils.SpawnError as exc:
         raise OperationError(exc)
Esempio n. 6
0
 def run(self):
     utils.spawn_async_notify_as("evolution.desktop",
                                 ['xdg-open', 'mailto:'])
Esempio n. 7
0
	def _make_archive(cls, filepaths):
		cmd = ["file-roller", "--add"]
		cmd.extend(filepaths)
		utils.spawn_async_notify_as("file-roller.desktop", cmd)
Esempio n. 8
0
	def activate(self, leaf):
		utils.spawn_async_notify_as("file-roller.desktop",
				["file-roller", "--extract-here", leaf.object])
Esempio n. 9
0
	def run(self):
		utils.spawn_async_notify_as("evolution.desktop",
		                           ['evolution', 'mailto:'])
Esempio n. 10
0
	def activate(self, leaf):
		text = leaf.object
		utils.spawn_async_notify_as("gnome-dictionary.desktop",
		                           ["gnome-dictionary", "--look-up=%s" % text])
Esempio n. 11
0
	def run(self):
		if (not utils.spawn_async_notify_as(
		        'thunderbird.desktop', ['thunderbird', '--compose'])):
			utils.spawn_async_notify_as(
					'icedove.desktop', ['icedove', '--compose'])
Esempio n. 12
0
 def _make_archive(cls, filepaths):
     cmd = ["file-roller", "--add"]
     cmd.extend(filepaths)
     utils.spawn_async_notify_as("file-roller.desktop", cmd)
Esempio n. 13
0
 def activate(self, leaf):
     utils.spawn_async_notify_as(
         "file-roller.desktop",
         ["file-roller", "--extract-here", leaf.object])