1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>TotemPlugin</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="index.html" title="Totem Reference Manual">
<link rel="up" href="core-api.html" title="Core API">
<link rel="prev" href="totem-Interface.html" title="Interface">
<link rel="next" href="BaconVideoWidget.html" title="BaconVideoWidget">
<meta name="generator" content="GTK-Doc V1.11 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
<link rel="chapter" href="tutorials.html" title="Tutorials">
<link rel="chapter" href="core-api.html" title="Core API">
<link rel="chapter" href="widget-api.html" title="Widgets">
<link rel="index" href="api-index-full.html" title="Index of all symbols">
<link rel="index" href="api-index-deprecated.html" title="Index of deprecated symbols">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="totem-Interface.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="core-api.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">Totem Reference Manual</th>
<td><a accesskey="n" href="BaconVideoWidget.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#TotemPlugin.synopsis" class="shortcut">Top</a>
|
<a href="#TotemPlugin.description" class="shortcut">Description</a>
|
<a href="#TotemPlugin.object-hierarchy" class="shortcut">Object Hierarchy</a>
|
<a href="#TotemPlugin.properties" class="shortcut">Properties</a>
</td></tr>
</table>
<div class="refentry" title="TotemPlugin">
<a name="TotemPlugin"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="TotemPlugin.top_of_page"></a>TotemPlugin</span></h2>
<p>TotemPlugin — base plugin class and loading/unloading functions</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1" title="Stability Level">
<a name="TotemPlugin.stability-level"></a><h2>Stability Level</h2>
Unstable, unless otherwise indicated
</div>
<div class="refsynopsisdiv" title="Synopsis">
<a name="TotemPlugin.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include <totem-plugin.h>
<a class="link" href="TotemPlugin.html#TotemPlugin-struct" title="TotemPlugin">TotemPlugin</a>;
<a class="link" href="TotemPlugin.html#TotemPluginClass" title="TotemPluginClass">TotemPluginClass</a>;
enum <a class="link" href="TotemPlugin.html#TotemPluginError" title="enum TotemPluginError">TotemPluginError</a>;
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> (<a class="link" href="TotemPlugin.html#TotemPluginActivationFunc" title="TotemPluginActivationFunc ()">*TotemPluginActivationFunc</a>) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem,
<a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
>GError</a> **error);
void (<a class="link" href="TotemPlugin.html#TotemPluginDeactivationFunc" title="TotemPluginDeactivationFunc ()">*TotemPluginDeactivationFunc</a>) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem);
<a
href="/usr/share/gtk-doc/html/gtk/GtkWidget.html"
>GtkWidget</a> * (<a class="link" href="TotemPlugin.html#TotemPluginWidgetFunc" title="TotemPluginWidgetFunc ()">*TotemPluginWidgetFunc</a>) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);
#define <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-DEFINE-TYPE--CAPS" title="TOTEM_PLUGIN_DEFINE_TYPE()">TOTEM_PLUGIN_DEFINE_TYPE</a> (TypeName, type_name, TYPE_PARENT)
#define <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER--CAPS" title="TOTEM_PLUGIN_REGISTER()">TOTEM_PLUGIN_REGISTER</a> (PluginName, plugin_name)
#define <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER-EXTENDED--CAPS" title="TOTEM_PLUGIN_REGISTER_EXTENDED()">TOTEM_PLUGIN_REGISTER_EXTENDED</a> (PluginName, plugin_name, _C_)
#define <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER-TYPE--CAPS" title="TOTEM_PLUGIN_REGISTER_TYPE()">TOTEM_PLUGIN_REGISTER_TYPE</a> (type_name)
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> <a class="link" href="TotemPlugin.html#totem-plugin-activate" title="totem_plugin_activate ()">totem_plugin_activate</a> (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem,
<a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
>GError</a> **error);
void <a class="link" href="TotemPlugin.html#totem-plugin-deactivate" title="totem_plugin_deactivate ()">totem_plugin_deactivate</a> (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem);
<a
href="/usr/share/gtk-doc/html/gtk/GtkWidget.html"
>GtkWidget</a> * <a class="link" href="TotemPlugin.html#totem-plugin-create-configure-dialog" title="totem_plugin_create_configure_dialog ()">totem_plugin_create_configure_dialog</a>
(<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> <a class="link" href="TotemPlugin.html#totem-plugin-is-configurable" title="totem_plugin_is_configurable ()">totem_plugin_is_configurable</a> (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);
<a
href="/usr/share/gtk-doc/html/gtk/GtkBuilder.html"
>GtkBuilder</a> * <a class="link" href="TotemPlugin.html#totem-plugin-load-interface" title="totem_plugin_load_interface ()">totem_plugin_load_interface</a> (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
const char *name,
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> fatal,
<a
href="/usr/share/gtk-doc/html/gtk/GtkWindow.html"
>GtkWindow</a> *parent,
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"
>gpointer</a> user_data);
char * <a class="link" href="TotemPlugin.html#totem-plugin-find-file" title="totem_plugin_find_file ()">totem_plugin_find_file</a> (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
const char *file);
</pre>
</div>
<div class="refsect1" title="Object Hierarchy">
<a name="TotemPlugin.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
<a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
>GObject</a>
+----TotemPlugin
</pre>
</div>
<div class="refsect1" title="Properties">
<a name="TotemPlugin.properties"></a><h2>Properties</h2>
<pre class="synopsis">
"<a class="link" href="TotemPlugin.html#TotemPlugin--name" title='The "name" property'>name</a>" <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>* : Read / Write
</pre>
</div>
<div class="refsect1" title="Description">
<a name="TotemPlugin.description"></a><h2>Description</h2>
<p>
<a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a> is a general-purpose architecture for adding plugins to Totem, with
derived support for different programming languages.</p>
<p>
</p>
</div>
<div class="refsect1" title="Details">
<a name="TotemPlugin.details"></a><h2>Details</h2>
<div class="refsect2" title="TotemPlugin">
<a name="TotemPlugin-struct"></a><h3>TotemPlugin</h3>
<pre class="programlisting">typedef struct _TotemPlugin TotemPlugin;</pre>
<p>
All the fields in the <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a> structure are private and should never be accessed directly.</p>
<p>
</p>
</div>
<hr>
<div class="refsect2" title="TotemPluginClass">
<a name="TotemPluginClass"></a><h3>TotemPluginClass</h3>
<pre class="programlisting">typedef struct {
GObjectClass parent_class;
/* Virtual public methods */
TotemPluginActivationFunc activate;
TotemPluginDeactivationFunc deactivate;
TotemPluginWidgetFunc create_configure_dialog;
} TotemPluginClass;
</pre>
<p>
The class structure for the <a
href="http://library.gnome.org/devel/totem-pl-parser/TotemPlParser.html"
><span class="type">TotemPlParser</span></a> type.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObjectClass"
>GObjectClass</a> <em class="structfield"><code>parent_class</code></em>;</span></p></td>
<td> the parent class
</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="TotemPlugin.html#TotemPluginActivationFunc" title="TotemPluginActivationFunc ()">TotemPluginActivationFunc</a> <em class="structfield"><code>activate</code></em>;</span></p></td>
<td> function called when activating a plugin using <a class="link" href="TotemPlugin.html#totem-plugin-activate" title="totem_plugin_activate ()"><code class="function">totem_plugin_activate()</code></a>.
It must be set by inheriting classes, and should return <code class="literal">TRUE</code> if it successfully created/got handles to
the resources needed by the plugin. If it returns <code class="literal">FALSE</code>, loading the plugin is abandoned.
</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="TotemPlugin.html#TotemPluginDeactivationFunc" title="TotemPluginDeactivationFunc ()">TotemPluginDeactivationFunc</a> <em class="structfield"><code>deactivate</code></em>;</span></p></td>
<td> function called when deactivating a plugin using <a class="link" href="TotemPlugin.html#totem-plugin-deactivate" title="totem_plugin_deactivate ()"><code class="function">totem_plugin_deactivate()</code></a>;
It must be set by inheriting classes, and should free/unref any resources the plugin used.
</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="TotemPlugin.html#TotemPluginWidgetFunc" title="TotemPluginWidgetFunc ()">TotemPluginWidgetFunc</a> <em class="structfield"><code>create_configure_dialog</code></em>;</span></p></td>
<td> function called when configuring a plugin using <a class="link" href="TotemPlugin.html#totem-plugin-create-configure-dialog" title="totem_plugin_create_configure_dialog ()"><code class="function">totem_plugin_create_configure_dialog()</code></a>.
If non-<code class="literal">NULL</code>, it should create and return the plugin's configuration dialog. If <code class="literal">NULL</code>, the plugin is not
configurable.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="enum TotemPluginError">
<a name="TotemPluginError"></a><h3>enum TotemPluginError</h3>
<pre class="programlisting">typedef enum {
TOTEM_PLUGIN_ERROR_ACTIVATION
} TotemPluginError;
</pre>
<p>
Error codes returned by <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a> operations.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><a name="TOTEM-PLUGIN-ERROR-ACTIVATION--CAPS"></a><span class="term"><code class="literal">TOTEM_PLUGIN_ERROR_ACTIVATION</code></span></p></td>
<td> there was an error activating the plugin
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TotemPluginActivationFunc ()">
<a name="TotemPluginActivationFunc"></a><h3>TotemPluginActivationFunc ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> (*TotemPluginActivationFunc) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem,
<a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
>GError</a> **error);</pre>
<p>
Called when the user has requested <em class="parameter"><code>plugin</code></em> be activated, this function should be used to initialise
any resources the plugin needs, and attach itself to the Totem UI.
</p>
<p>
If an error is encountered while setting up the plugin, <em class="parameter"><code>error</code></em> should be set, and the function
should return <code class="literal">FALSE</code>. Totem will then not mark the plugin as activated, and will ensure it's not loaded
again unless explicitly asked for by the user.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> the <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>totem</code></em> :</span></p></td>
<td> a <a class="link" href="TotemObject.html" title="TotemObject"><span class="type">TotemObject</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
><span class="type">GError</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">TRUE</code> on success, <code class="literal">FALSE</code> otherwise
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TotemPluginDeactivationFunc ()">
<a name="TotemPluginDeactivationFunc"></a><h3>TotemPluginDeactivationFunc ()</h3>
<pre class="programlisting">void (*TotemPluginDeactivationFunc) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem);</pre>
<p>
Called when the user has requested <em class="parameter"><code>plugin</code></em> be deactivated, this function should destroy all resources
created during the plugin's lifetime, especially those created in the activation function.
</p>
<p>
It should be possible to activate and deactivate the plugin multiple times sequentially in a single Totem
session without memory or resource leaks, or errors.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> the <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>totem</code></em> :</span></p></td>
<td> a <a class="link" href="TotemObject.html" title="TotemObject"><span class="type">TotemObject</span></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TotemPluginWidgetFunc ()">
<a name="TotemPluginWidgetFunc"></a><h3>TotemPluginWidgetFunc ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/gtk/GtkWidget.html"
>GtkWidget</a> * (*TotemPluginWidgetFunc) (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);</pre>
<p>
Called when the configuration dialogue for the plugin needs to be built, this function should return
a complete window which will be shown by the Totem code. The widget needs to be capable of hiding itself
when configuration is complete.
</p>
<p>
If your plugin is not configurable, do not define this function.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> the <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gtk/GtkWidget.html"
><span class="type">GtkWidget</span></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TOTEM_PLUGIN_DEFINE_TYPE()">
<a name="TOTEM-PLUGIN-DEFINE-TYPE--CAPS"></a><h3>TOTEM_PLUGIN_DEFINE_TYPE()</h3>
<pre class="programlisting">#define TOTEM_PLUGIN_DEFINE_TYPE(TypeName, type_name, TYPE_PARENT)</pre>
<p>
Registers a type to be used inside a Totem plugin, but not the plugin's itself;
use <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER--CAPS" title="TOTEM_PLUGIN_REGISTER()"><code class="function">TOTEM_PLUGIN_REGISTER()</code></a> for that.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>TypeName</code></em> :</span></p></td>
<td> the type name in camelcase
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>type_name</code></em> :</span></p></td>
<td> the type name in lowercase, with underscores
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>TYPE_PARENT</code></em> :</span></p></td>
<td> the type's parent name in uppercase, with underscores
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TOTEM_PLUGIN_REGISTER()">
<a name="TOTEM-PLUGIN-REGISTER--CAPS"></a><h3>TOTEM_PLUGIN_REGISTER()</h3>
<pre class="programlisting">#define TOTEM_PLUGIN_REGISTER(PluginName, plugin_name)</pre>
<p>
Registers a new Totem plugin type. A plugin is, at its core, just a class which is
instantiated and activated on the user's request. This macro registers that class.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>PluginName</code></em> :</span></p></td>
<td> the plugin's name in camelcase
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin_name</code></em> :</span></p></td>
<td> the plugin's name in lowercase, with underscores
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TOTEM_PLUGIN_REGISTER_EXTENDED()">
<a name="TOTEM-PLUGIN-REGISTER-EXTENDED--CAPS"></a><h3>TOTEM_PLUGIN_REGISTER_EXTENDED()</h3>
<pre class="programlisting">#define TOTEM_PLUGIN_REGISTER_EXTENDED(PluginName, plugin_name, _C_)</pre>
<p>
Registers a new Totem plugin type with custom code in the module type registration
function. See <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER--CAPS" title="TOTEM_PLUGIN_REGISTER()"><code class="function">TOTEM_PLUGIN_REGISTER()</code></a> for more information about the registration
process.
</p>
<p>
A variable named <em class="parameter"><code>our_info</code></em> is available with the module's <a
href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GTypeInfo"
><span class="type">GTypeInfo</span></a> information.
<em class="parameter"><code>plugin_module_type</code></em> is the plugin's <a
href="/usr/share/gtk-doc/html/gobject/GTypeModule.html"
><span class="type">GTypeModule</span></a>.
@<em class="replaceable"><code>plugin_name</code></em>_type is the plugin's newly-registered <a
href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"
><span class="type">GType</span></a>
(where <em class="replaceable"><code>plugin_name</code></em> is the plugin name passed to the
<a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-REGISTER-EXTENDED--CAPS" title="TOTEM_PLUGIN_REGISTER_EXTENDED()"><code class="function">TOTEM_PLUGIN_REGISTER_EXTENDED()</code></a> macro).</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>PluginName</code></em> :</span></p></td>
<td> the plugin's name in camelcase
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin_name</code></em> :</span></p></td>
<td> the plugin's name in lowercase, with underscores
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>_C_</code></em> :</span></p></td>
<td> extra code to call in the module type registration function
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="TOTEM_PLUGIN_REGISTER_TYPE()">
<a name="TOTEM-PLUGIN-REGISTER-TYPE--CAPS"></a><h3>TOTEM_PLUGIN_REGISTER_TYPE()</h3>
<pre class="programlisting">#define TOTEM_PLUGIN_REGISTER_TYPE(type_name)</pre>
<p>
Calls the type registration function for a type inside a plugin module previously
defined with <a class="link" href="TotemPlugin.html#TOTEM-PLUGIN-DEFINE-TYPE--CAPS" title="TOTEM_PLUGIN_DEFINE_TYPE()"><code class="function">TOTEM_PLUGIN_DEFINE_TYPE()</code></a>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>type_name</code></em> :</span></p></td>
<td> the type's name in lowercase, with underscores
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_activate ()">
<a name="totem-plugin-activate"></a><h3>totem_plugin_activate ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> totem_plugin_activate (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem,
<a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
>GError</a> **error);</pre>
<p>
Activates the passed <em class="parameter"><code>plugin</code></em> by calling its activate method.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>totem</code></em> :</span></p></td>
<td> a <a class="link" href="TotemObject.html" title="TotemObject"><span class="type">TotemObject</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td> return location for a <a
href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"
><span class="type">GError</span></a>, or <code class="literal">NULL</code>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">TRUE</code> on success
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_deactivate ()">
<a name="totem-plugin-deactivate"></a><h3>totem_plugin_deactivate ()</h3>
<pre class="programlisting">void totem_plugin_deactivate (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
<a class="link" href="TotemObject.html" title="TotemObject">TotemObject</a> *totem);</pre>
<p>
Deactivates <em class="parameter"><code>plugin</code></em> by calling its deactivate method.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>totem</code></em> :</span></p></td>
<td> a <a class="link" href="TotemObject.html" title="TotemObject"><span class="type">TotemObject</span></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_create_configure_dialog ()">
<a name="totem-plugin-create-configure-dialog"></a><h3>totem_plugin_create_configure_dialog ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/gtk/GtkWidget.html"
>GtkWidget</a> * totem_plugin_create_configure_dialog
(<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);</pre>
<p>
Returns the plugin's configuration dialog, as created by
the plugin's create_configure_dialog method.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> the configuration dialog, or <code class="literal">NULL</code>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_is_configurable ()">
<a name="totem-plugin-is-configurable"></a><h3>totem_plugin_is_configurable ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> totem_plugin_is_configurable (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin);</pre>
<p>
Returns <code class="literal">TRUE</code> if the plugin is configurable and has a
configuration dialog. It calls the plugin's
is_configurable method.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">TRUE</code> if the plugin is configurable
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_load_interface ()">
<a name="totem-plugin-load-interface"></a><h3>totem_plugin_load_interface ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/gtk/GtkBuilder.html"
>GtkBuilder</a> * totem_plugin_load_interface (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
const char *name,
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a> fatal,
<a
href="/usr/share/gtk-doc/html/gtk/GtkWindow.html"
>GtkWindow</a> *parent,
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"
>gpointer</a> user_data);</pre>
<p>
Loads an interface file (GtkBuilder UI file) for a plugin, given its filename and
assuming it's installed in the plugin's data directory.
</p>
<p>
This should be used instead of attempting to load interfaces manually in plugins.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td>
<td> interface filename
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>fatal</code></em> :</span></p></td>
<td> <code class="literal">TRUE</code> if it's a fatal error if the interface can't be loaded
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>parent</code></em> :</span></p></td>
<td> the interface's parent <a
href="/usr/share/gtk-doc/html/gtk/GtkWindow.html"
><span class="type">GtkWindow</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
<td> a pointer to be passed to each signal handler in the interface when they're called
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> the <a
href="/usr/share/gtk-doc/html/gtk/GtkBuilder.html"
><span class="type">GtkBuilder</span></a> instance for the interface
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="totem_plugin_find_file ()">
<a name="totem-plugin-find-file"></a><h3>totem_plugin_find_file ()</h3>
<pre class="programlisting">char * totem_plugin_find_file (<a class="link" href="TotemPlugin.html" title="TotemPlugin">TotemPlugin</a> *plugin,
const char *file);</pre>
<p>
Finds the specified <em class="parameter"><code>file</code></em> by looking in the plugin paths
listed by <code class="function">totem_get_plugin_paths()</code> and then in the system
Totem data directory.
</p>
<p>
This should be used by plugins to find plugin-specific
resource files.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>plugin</code></em> :</span></p></td>
<td> a <a class="link" href="TotemPlugin.html" title="TotemPlugin"><span class="type">TotemPlugin</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>file</code></em> :</span></p></td>
<td> the file to find
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a newly-allocated absolute path for the file, or <code class="literal">NULL</code>
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
<div class="refsect1" title="Property Details">
<a name="TotemPlugin.property-details"></a><h2>Property Details</h2>
<div class="refsect2" title='The "name" property'>
<a name="TotemPlugin--name"></a><h3>The <code class="literal">"name"</code> property</h3>
<pre class="programlisting"> "name" <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>* : Read / Write</pre>
<p>
The plugin's name. It should be a construction property, but due to the Python plugin hack, it
can't be: do not change the name after construction. Should be the same as used for naming plugin-
specific resources.</p>
<p>
</p>
<p>Default value: NULL</p>
</div>
</div>
</div>
<div class="footer">
<hr>
Generated by GTK-Doc V1.11</div>
</body>
</html>
|