Back to index

unity  6.0.0
Public Member Functions
unity::UnityPluginVTable Class Reference

Your vTable class is some basic info about the plugin that core uses. More...

#include <unityshell.h>

List of all members.

Public Member Functions

bool init ()

Detailed Description

Your vTable class is some basic info about the plugin that core uses.

Definition at line 438 of file unityshell.h.


Member Function Documentation

Definition at line 3129 of file unityshell.cpp.

{
  if (!CompPlugin::checkPluginABI("core", CORE_ABIVERSION))
    return false;
  if (!CompPlugin::checkPluginABI("composite", COMPIZ_COMPOSITE_ABI))
    return false;
  if (!CompPlugin::checkPluginABI("opengl", COMPIZ_OPENGL_ABI))
    return false;

  /*
   * GTK needs to be initialized or else unity's gdk/gtk calls will crash.
   * This is already done in compiz' main() if using ubuntu packages, but not
   * if you're using the regular (upstream) compiz.
   * Admittedly this is the same as what the "gtkloader" plugin does. But it
   * is faster, more efficient (one less plugin in memory), and more reliable
   * to do the init here where its needed. And yes, init'ing multiple times is
   * safe, and does nothing after the first init.
   */
  if (!gtk_init_check(&programArgc, &programArgv))
  {
    compLogMessage("unityshell", CompLogLevelError, "GTK init failed\n");
    return false;
  }

  return true;
}

The documentation for this class was generated from the following files: