Imported Upstream version 2.28.4
[platform/upstream/pygobject2.git] / docs / html / class-gioapplaunchcontext.html
1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>gio.AppLaunchContext</title><link rel="stylesheet" type="text/css" href="style.css"><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="PyGObject Reference Manual"><link rel="up" href="gio-class-reference.html" title="PyGio Class Reference"><link rel="prev" href="class-gioappinfo.html" title="gio.AppInfo"><link rel="next" href="class-gioasyncresult.html" title="gio.AsyncResult"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gio.AppLaunchContext</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-gioappinfo.html">Prev</a> </td><th width="60%" align="center">PyGio Class Reference</th><td width="20%" align="right"> <a accesskey="n" href="class-gioasyncresult.html">Next</a></td></tr></table><hr></div><div class="refentry" title="gio.AppLaunchContext"><a name="class-gioapplaunchcontext"></a><div class="titlepage"></div><div class="refnamediv"><h2>gio.AppLaunchContext</h2><p>gio.AppLaunchContext — Application launch context.</p></div><div class="refsect1" title="Synopsis"><a name="id724313"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gio.AppLaunchContext</span></span>(<span class="ooclass"><span class="classname"><a class="link" href="class-gobject.html" title="gobject.GObject">gobject.GObject</a></span></span>):
2 <code class="constructorsynopsis">    <span class="methodname"><a class="link" href="class-gioapplaunchcontext.html#constructor-gioapplaunchcontext" title="Constructor">gio.AppLaunchContext</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gioapplaunchcontext.html#method-gioapplaunchcontext--get-display" title="gio.AppLaunchContext.get_display">get_display</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>info</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gioapplaunchcontext.html#method-gioapplaunchcontext--get-startup-notify-id" title="gio.AppLaunchContext.get_startup_notify_id">get_startup_notify_id</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>info</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gioapplaunchcontext.html#method-gioapplaunchcontext--launch-failed" title="gio.AppLaunchContext.launch_failed">launch_failed</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>startup_notify_id</code></strong></span></span>)</code><br></pre></td></tr></table></div><div class="refsect1" title="Ancestry"><a name="id715648"></a><h2>Ancestry</h2><pre class="synopsis">+-- <a class="link" href="class-gobject.html" title="gobject.GObject">gobject.GObject</a>
3   +-- <a class="link" href="class-gioapplaunchcontext.html" title="gio.AppLaunchContext">gio.AppLaunchContext</a>
4 </pre></div><div class="refsect1" title="Description"><a name="id715627"></a><h2>Description</h2><p>
5             The <a class="link" href="class-gioapplaunchcontext.html" title="gio.AppLaunchContext"><code class="classname">gio.AppLaunchContext</code></a>
6             is used for integrating the launch with the launching application. This is used to handle for
7             instance startup notification and launching the new application on the same screen as the launching window.
8         </p></div><div class="refsect1" title="Constructor"><a name="constructor-gioapplaunchcontext"></a><h2>Constructor</h2><pre class="programlisting"><code class="constructorsynopsis">    <span class="methodname">gio.AppLaunchContext</span>(<span class="methodparam"></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a new
9                 <a class="link" href="class-gioapplaunchcontext.html" title="gio.AppLaunchContext"><code class="classname">gio.AppLaunchContext</code></a>.
10                 </td></tr></tbody></table><p>
11             Creates a new application launch context. This is not normally used, instead
12             you instantiate a subclass of this, such as
13             <PYGTKDOCLINK HREF="class-gdkapplaunchcontext"><code class="classname">gtk.gdk.AppLaunchContext</code></PYGTKDOCLINK>.
14         </p></div><div class="refsect1" title="Methods"><a name="id715552"></a><h2>Methods</h2><div class="refsect2" title="gio.AppLaunchContext.get_display"><a name="method-gioapplaunchcontext--get-display"></a><h3>gio.AppLaunchContext.get_display</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_display</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>info</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>info</code></em> :</span></p></td><td>a
15                     <a class="link" href="class-gioappinfo.html" title="gio.AppInfo"><code class="classname">gio.AppInfo</code></a>
16                     </td></tr><tr><td><p><span class="term"><em class="parameter"><code>files</code></em> :</span></p></td><td>a list of
17                     <a class="link" href="class-giofile.html" title="gio.File"><code class="classname">gio.File</code></a>
18                     objects.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a display string for the display. 
19                     </td></tr></tbody></table><p>
20                 The <code class="methodname">get_display</code>() method gets the display
21                 string for the display. This is used to ensure new applications
22                 are started on the same display as the launching application.
23             </p></div><div class="refsect2" title="gio.AppLaunchContext.get_startup_notify_id"><a name="method-gioapplaunchcontext--get-startup-notify-id"></a><h3>gio.AppLaunchContext.get_startup_notify_id</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_startup_notify_id</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>info</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>info</code></em> :</span></p></td><td>a
24                     <a class="link" href="class-gioappinfo.html" title="gio.AppInfo"><code class="classname">gio.AppInfo</code></a>
25                     </td></tr><tr><td><p><span class="term"><em class="parameter"><code>files</code></em> :</span></p></td><td>a list of
26                     <a class="link" href="class-giofile.html" title="gio.File"><code class="classname">gio.File</code></a>
27                     objects.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a startup notification ID for the application,
28                     or <code class="literal">None</code> if not supported. 
29                     </td></tr></tbody></table><p>
30                 The <code class="methodname">get_startup_notify_id</code>() method initiates
31                 startup notification for the application and returns the DESKTOP_STARTUP_ID
32                 for the launched operation, if supported. 
33             </p><p>
34                 Startup notification IDs are defined in the FreeDesktop.Org Startup Notifications standard.
35             </p></div><div class="refsect2" title="gio.AppLaunchContext.launch_failed"><a name="method-gioapplaunchcontext--launch-failed"></a><h3>gio.AppLaunchContext.launch_failed</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">launch_failed</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>startup_notify_id</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>startup_notify_id</code></em> :</span></p></td><td>the startup notification id that was returned by
36                     <code class="methodname"><a class="link" href="class-gioapplaunchcontext.html#method-gioapplaunchcontext--get-startup-notify-id" title="gio.AppLaunchContext.get_startup_notify_id">get_startup_notify_id</a></code>.
37                     </td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a startup notification ID for the application,
38                     or <code class="literal">None</code> if not supported. 
39                     </td></tr></tbody></table><p>
40                 The <code class="methodname">get_startup_notify_id</code>() method is called
41                 when an application has failed to launch, so that it can cancel the application
42                 startup notification started in
43                 <code class="methodname"><a class="link" href="class-gioapplaunchcontext.html#method-gioapplaunchcontext--get-startup-notify-id" title="gio.AppLaunchContext.get_startup_notify_id">get_startup_notify_id</a></code>
44             </p></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="class-gioappinfo.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="gio-class-reference.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="class-gioasyncresult.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">gio.AppInfo </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> gio.AsyncResult</td></tr></table></div></body></html>