~ubuntu-branches/ubuntu/natty/vino/natty

« back to all changes in this revision

Viewing changes to server/vino-main.c

  • Committer: Bazaar Package Importer
  • Author(s): Robert Ancell
  • Date: 2009-07-28 11:22:09 UTC
  • mfrom: (1.1.36 upstream)
  • Revision ID: james.westby@ubuntu.com-20090728112209-suoi0rmpr0ogmcfv
Tags: 2.27.5-0ubuntu1
* New upstream release: (LP: #405585)
  - Added an (GConf) option to disable XDamage extension. See #533613.
  - Added Telepathy tubes support, allowing you to share the desktop with an
    IM buddy. (Arnaud Maillet)
  - Dropped libgnome dependency. Using EggSmClient.
  - Migrate from libglade to GtkBuilder. (Javier Jardón)
  - Many small bug fixes.
* debian/control.in:
  - Remove dependency on libglade
  - Remove Debian VCS links as they confuse debcheckout
  - Added build-depends on telepathy-glib
* debian/watch:
  - Watch for unstable versions
* debian/patches/10_fix_link_order.patch:
* debian/patches/99_autoreconf.patch:
  - Fix link order of server libraries (committed upstream, patch can be
    removed next release)

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
 
24
24
#include <config.h>
25
25
 
 
26
#include <glib.h>
 
27
#include <glib/gi18n.h>
26
28
#include <gtk/gtk.h>
 
29
#include <locale.h>
27
30
 
28
31
#include "vino-input.h"
29
32
#include "vino-mdns.h"
31
34
#include "vino-prefs.h"
32
35
#include "vino-util.h"
33
36
#include "vino-dbus-listener.h"
34
 
#include <libgnome/libgnome.h>
35
 
#include <libgnomeui/libgnomeui.h>
 
37
#include "eggsmclient.h"
36
38
 
37
39
#ifdef HAVE_GNUTLS
38
40
#include <gnutls/gnutls.h>
50
52
int
51
53
main (int argc, char **argv)
52
54
{
53
 
  GdkDisplay *display;
54
 
  gboolean    view_only;
55
 
  int         i, n_screens;
56
 
  GnomeClient *session;
57
 
  char        *restart_argv [] = { *argv, 0 };
 
55
  GOptionContext *context;
 
56
  GdkDisplay     *display;
 
57
  gboolean        view_only;
 
58
  int             i, n_screens;
 
59
  GError         *error = NULL;
 
60
  EggSMClient    *client;
58
61
 
 
62
  setlocale (LC_ALL, "");
59
63
  bindtextdomain (GETTEXT_PACKAGE, VINO_LOCALEDIR);
60
64
  bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
61
65
  textdomain (GETTEXT_PACKAGE);
62
66
 
63
 
  gnome_program_init ("vino", VERSION,
64
 
                      LIBGNOMEUI_MODULE,
65
 
                      argc, argv,
66
 
                      NULL);
67
 
 
68
 
  session = gnome_master_client ();
69
 
 
70
 
  gnome_client_set_restart_command (session, 2, restart_argv);
71
 
  gnome_client_set_restart_style   (session, GNOME_RESTART_IMMEDIATELY);
72
 
  gnome_client_set_priority        (session, 5);
73
 
  g_signal_connect (session, "die",
74
 
                    G_CALLBACK (gtk_main_quit), NULL);
 
67
  context = g_option_context_new (_("- VNC Server for GNOME"));
 
68
  g_option_context_add_group (context, gtk_get_option_group (TRUE));
 
69
  g_option_context_add_group (context, egg_sm_client_get_option_group ());
 
70
  g_option_context_parse (context, &argc, &argv, &error);
 
71
  if (error)
 
72
    {
 
73
      g_print ("%s\n%s\n",
 
74
               error->message,
 
75
               _("Run 'vino-server --help' to see a full list of available command line options"));
 
76
      g_error_free (error);
 
77
      return 1;
 
78
    }
 
79
 
 
80
  client = egg_sm_client_get ();
 
81
  g_signal_connect (client, "quit",
 
82
                    G_CALLBACK (gtk_main_quit), NULL);
75
83
 
76
84
  vino_setup_debug_flags ();
77
85