Exemplo n.º 1
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
    boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");
    boost::shared_ptr<Ekiga::PersonalDetails> details = core.get<Ekiga::PersonalDetails> ("personal-details");

    if (presence_core && call_core && details) {

      boost::shared_ptr<Avahi::PresencePublisher> publisher (new Avahi::PresencePublisher (core, *details, *call_core));
      if (core.add (publisher)) {

	presence_core->add_presence_publisher (publisher);
	result = true;
      }

      boost::shared_ptr<Avahi::Cluster> cluster = Avahi::Cluster::create (core);
      if (core.add (cluster)) {
	presence_core->add_cluster (cluster);
	result = true;
      }
    }

    return result;
  }
bool
local_roster_bridge_init (Ekiga::ServiceCore &core,
			  int * /*argc*/,
			  char ** /*argv*/[])
{
  bool result = false;
  Ekiga::ContactCore *contact_core = NULL;
  Local::Cluster *cluster = NULL;
  Local::ContactDecorator *decorator = NULL;

  contact_core
    = dynamic_cast<Ekiga::ContactCore*>(core.get ("contact-core"));

  cluster
    = dynamic_cast<Local::Cluster*>(core.get ("local-cluster"));

  if (cluster != NULL && contact_core != NULL) {

    decorator = new Local::ContactDecorator (*cluster);
    core.add (*decorator);
    contact_core->add_contact_decorator (*decorator);
    result = true;
  }

  return result;
}
Exemplo n.º 3
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
    boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
    boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");
    boost::shared_ptr<Ekiga::ChatCore> chat_core = core.get<Ekiga::ChatCore> ("chat-core");
    boost::shared_ptr<Ekiga::AccountCore> account_core = core.get<Ekiga::AccountCore> ("account-core");
    boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
    boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
    boost::shared_ptr<Ekiga::AudioOutputCore> audiooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
    boost::shared_ptr<Ekiga::VideoOutputCore> videooutput_core = core.get<Ekiga::VideoOutputCore> ("videooutput-core");
    boost::shared_ptr<Ekiga::PersonalDetails> personal_details = core.get<Ekiga::PersonalDetails> ("personal-details");
    boost::shared_ptr<Bank> account_store = core.get<Bank> ("opal-account-store");
    Ekiga::ServicePtr sip_endpoint = core.get ("opal-sip-endpoint");

    if (contact_core && presence_core && call_core && chat_core
	&& account_core && audioinput_core && videoinput_core
	&& audiooutput_core && videooutput_core && personal_details
	&& !account_store && !sip_endpoint) {

      PIPSocket::SetSuppressCanonicalName (true);  // avoid long delays

      hook_ekiga_plugins_to_opal (core);

      boost::shared_ptr<CallManager> call_manager (new CallManager (core));
      core.add (call_manager);

      boost::shared_ptr<Sip::EndPoint> sip_manager (new Sip::EndPoint (*call_manager, core), null_deleter ());
      std::cout << "FIXME: where is H323" << std::endl << std::flush;
      sip_manager->setup ();
      call_manager->set_sip_endpoint (sip_manager);
      core.add (sip_manager);

      boost::shared_ptr<Bank> bank (new Bank (core));
      account_core->add_bank (bank);
      presence_core->add_cluster (bank);
      core.add (bank);
      contact_core->add_contact_decorator (bank);
      presence_core->add_presentity_decorator (bank);
      call_manager->ready.connect (boost::bind (&Opal::Bank::call_manager_ready, &*bank));
      call_manager->setup ();
      presence_core->add_presence_publisher (bank);
      presence_core->add_presence_fetcher (bank);

      call_core->add_manager (call_manager);

      presence_core->add_supported_uri (&is_supported_address); //FIXME

      result = true;
    }

    return result;
  }
GMAudioOutputManager_null::GMAudioOutputManager_null (Ekiga::ServiceCore & _core)
: core (_core),
  runtime (*(dynamic_cast<Ekiga::Runtime *> (_core.get ("runtime"))))
{
  current_state[Ekiga::primary].opened = false;
  current_state[Ekiga::secondary].opened = false;
}
Exemplo n.º 5
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::PresenceCore> presence = core.get<Ekiga::PresenceCore> ("presence-core");
    boost::shared_ptr<Ekiga::AccountCore> account = core.get<Ekiga::AccountCore> ("account-core");
    boost::shared_ptr<Ekiga::ChatCore> chat = core.get<Ekiga::ChatCore> ("chat-core");
    boost::shared_ptr<Ekiga::PersonalDetails> details = core.get<Ekiga::PersonalDetails> ("personal-details");

    if (presence && account && chat && details) {

      LM::DialectPtr dialect(new LM::Dialect (core));
      LM::ClusterPtr cluster(new LM::Cluster (dialect, details));
      LM::BankPtr bank (new LM::Bank (details, dialect, cluster));
      if (core.add (bank)) {

	chat->add_dialect (dialect);
	account->add_bank (bank);
	presence->add_cluster (cluster);
	result = true;
      }
    }

    return result;
  }
Exemplo n.º 6
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* argc,
			    char** argv[])
  {
    boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
    boost::shared_ptr<Ekiga::AudioOutputCore> audiooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
    boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");

    if (audioinput_core && audiooutput_core && videoinput_core) {

      if (gst_init_check (argc, argv, NULL)) {

	GST::VideoInputManager* video = new GST::VideoInputManager ();
	GST::AudioInputManager* audioin = new GST::AudioInputManager ();
	GST::AudioOutputManager* audioout = new GST::AudioOutputManager ();
	Ekiga::ServicePtr service (new GStreamerService);

	if (core.add (service)) {

	  audioinput_core->add_manager (*audioin);
	  audiooutput_core->add_manager (*audioout);
	  videoinput_core->add_manager (*video);
	  result = true;
	}
      } else {

	std::cout << "gst_init_check failed" << std::endl; // FIXME: remove
      }
    }

    return result;
  }
Exemplo n.º 7
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    Ekiga::ServicePtr service = core.get ("xcap-core");

    if ( !service) {

      boost::shared_ptr<XCAP::Core> xcap(new XCAP::Core ());

      core.add (xcap);
      result = true;
    }

    return result;
  }
Exemplo n.º 8
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    Ekiga::ServicePtr service = core.get ("resource-list");
    boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
    boost::shared_ptr<XCAP::Core> xcap = core.get<XCAP::Core> ("xcap-core");

    if ( !service && presence_core && xcap) {

      boost::shared_ptr<RL::Cluster> cluster (new RL::Cluster (core));
      core.add (cluster);
      presence_core->add_cluster (cluster);
      result = true;
    }

    return result;
  }
Exemplo n.º 9
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    gmref_ptr<Ekiga::HalCore> hal_core = core.get ("hal-core");

    if (hal_core) {

      HalManager_dbus *hal_manager = new HalManager_dbus(core);

      hal_core->add_manager (*hal_manager);
      core.add (gmref_ptr<Ekiga::Service> (new Ekiga::BasicService ("hal-dbus",
								    "\tComponent bringing HAL through DBUS")));
      result = true;
    }

    return result;
  }
Exemplo n.º 10
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    gmref_ptr<Ekiga::Service> service = core.get ("call-history-store");
    gmref_ptr<Ekiga::ContactCore> contact_core = core.get ("contact-core");
    gmref_ptr<Ekiga::CallCore> call_core = core.get ("call-core");

    if (contact_core && call_core && !service) {

      gmref_ptr<History::Source> source (new History::Source (core));
      core.add (source);
      contact_core->add_source (source);
      result = true;
    }

    return result;
  }
Exemplo n.º 11
0
/* The Methods */
PVideoOutputDevice_EKIGA::PVideoOutputDevice_EKIGA (Ekiga::ServiceCore & _core)
: core (_core), videooutput_core (*(dynamic_cast<Ekiga::VideoOutputCore *> (_core.get ("videooutput-core"))))
{ 
 PWaitAndSignal m(videoDisplay_mutex);

  is_active = FALSE;
  
  /* Used to distinguish between input and output device. */
  device_id = 0; 
}
Exemplo n.º 12
0
bool
local_roster_init (Ekiga::ServiceCore &core,
                   int */*argc*/,
                   char **/*argv*/[])
{
    bool result = false;
    Ekiga::PresenceCore *presence_core = NULL;
    Local::Cluster *cluster = NULL;

    presence_core
        = dynamic_cast<Ekiga::PresenceCore*>(core.get ("presence-core"));

    if (presence_core != NULL) {

        cluster = new Local::Cluster (core);
        core.add (*cluster);
        presence_core->add_cluster (*cluster);
        result = true;
    }

    return result;
}
Exemplo n.º 13
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    gmref_ptr<Ekiga::ContactCore> contact_core = core.get ("contact-core");
    gmref_ptr<Ekiga::PresenceCore> presence_core = core.get ("presence-core");
    gmref_ptr<Ekiga::CallCore> call_core = core.get ("call-core");
    gmref_ptr<Ekiga::ChatCore> chat_core = core.get ("chat-core");
    gmref_ptr<Ekiga::AccountCore> account_core = core.get ("account-core");

    if (contact_core && presence_core && call_core && chat_core && account_core) {

      gmref_ptr<CallManager> call_manager (new CallManager (core));

      gmref_ptr<Opal::Bank> bank (new Bank (core));

      account_core->add_bank (bank);
      core.add (bank);
      call_manager->ready.connect (sigc::mem_fun (&*bank, &Opal::Bank::call_manager_ready));

      unsigned sip_port = gm_conf_get_int (SIP_KEY "listen_port");
      gmref_ptr<Sip::EndPoint> sip_manager (new Sip::EndPoint (*call_manager, core, sip_port));
      call_manager->add_protocol_manager (sip_manager);
      account_core->add_account_subscriber (*sip_manager);
      contact_core->add_contact_decorator (sip_manager);
      presence_core->add_presentity_decorator (sip_manager);
      presence_core->add_presence_fetcher (sip_manager);
      presence_core->add_presence_publisher (sip_manager);

#ifdef HAVE_H323
      unsigned h323_port = gm_conf_get_int (H323_KEY "listen_port");
      gmref_ptr<H323::EndPoint> h323_manager (new H323::EndPoint (*call_manager, core, h323_port));
      call_manager->add_protocol_manager (h323_manager);
      account_core->add_account_subscriber (*h323_manager);
      contact_core->add_contact_decorator (h323_manager);
      presence_core->add_presentity_decorator (h323_manager);
#endif

      call_core->add_manager (call_manager);

      core.add (call_manager);

      new ConfBridge (*call_manager); // FIXME: isn't that leaked!?

      presence_core->add_supported_uri (sigc::ptr_fun (is_supported_address)); //FIXME

      OpalLinkerHacks::loadOpalVideoInput = 1;
      OpalLinkerHacks::loadOpalVideoOutput = 1;
      OpalLinkerHacks::loadOpalAudio = 1;

      result = true;
    }

    return result;
  }
Exemplo n.º 14
0
bool
gtk_core_init (Ekiga::ServiceCore &core,
	       int *argc,
	       char **argv[])
{
  if (gtk_init_check (argc, argv)) {

    boost::shared_ptr<Gtk::Core> gtk (new Gtk::Core);

    core.add (gtk);

    return true;

  } else
    return false;
}
Exemplo n.º 15
0
bool
gtk_core_init (Ekiga::ServiceCore &core,
	       int *argc,
	       char **argv[])
{
  if (gtk_init_check (argc, argv)) {

    Gtk::Core *gtk = new Gtk::Core ();

    core.add (*gtk);

    return true;

  } else
    return false;
}
Exemplo n.º 16
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");

    if (contact_core) {

      boost::shared_ptr<OPENLDAP::Source> service (OPENLDAP::Source::create (core));
      core.add (service);
      contact_core->add_source (service);
      sasl_client_init (NULL); // FIXME: shouldn't it be done by the source!?
      result = true;
    }

    return result;
  }
Exemplo n.º 17
0
/* The class */
Opal::Sip::EndPoint::EndPoint (Opal::CallManager & _manager, 
                               Ekiga::ServiceCore & _core, 
                               unsigned _listen_port)
:   SIPEndPoint (_manager),
    manager (_manager), 
    core (_core),
    presence_core (*(dynamic_cast<Ekiga::PresenceCore *> (core.get ("presence-core")))),
    runtime (*(dynamic_cast<Ekiga::Runtime *> (core.get ("runtime")))),
    account_core (*(dynamic_cast<Ekiga::AccountCore *> (core.get ("account-core"))))
{
  Ekiga::ChatCore* chat_core;

  protocol_name = "sip";
  uri_prefix = "sip:";
  listen_port = _listen_port;

  chat_core = dynamic_cast<Ekiga::ChatCore *> (core.get ("chat-core"));
  dialect = new SIP::Dialect (core, sigc::mem_fun (this, &Opal::Sip::EndPoint::send_message));
  chat_core->add_dialect (*dialect);

  /* Timeouts */
  SetAckTimeout (PTimeInterval (0, 32));
  SetPduCleanUpTimeout (PTimeInterval (0, 1));
  SetInviteTimeout (PTimeInterval (0, 6));
  SetNonInviteTimeout (PTimeInterval (0, 6));
  SetRetryTimeouts (500, 4000);
  SetMaxRetries (8);

  /* Start listener */
  set_listen_port (listen_port);

  /* Update the User Agent */
  SetUserAgent ("Ekiga/" PACKAGE_VERSION);

  /* Ready to take calls */
  manager.AddRouteEntry("sip:.* = pc:<db>");
  manager.AddRouteEntry("pc:.* = sip:<da>");

  /* NAT Binding */
  SetNATBindingRefreshMethod (SIPEndPoint::EmptyRequest);

  Ekiga::PersonalDetails *details = dynamic_cast<Ekiga::PersonalDetails *> (_core.get ("personal-details"));
  if (details)
    publish (*details);
}
Exemplo n.º 18
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");

    if (audioinput_core) {

      GMAudioInputManager_null *audioinput_manager = new GMAudioInputManager_null(core);

      audioinput_core->add_manager (*audioinput_manager);
      core.add (Ekiga::ServicePtr (new Ekiga::BasicService ("null-audio-input",
							    "\tComponent bringing silent audio input")));
      result = true;
    }

    return result;
  }
Exemplo n.º 19
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");

    if (videoinput_core) {

      GMVideoInputManager_ptlib *videoinput_manager = new GMVideoInputManager_ptlib;

      videoinput_core->add_manager (*videoinput_manager);
      core.add (Ekiga::ServicePtr (new Ekiga::BasicService ("ptlib-video-input",
							    "\tComponent bringing PTLIB's video input")));
      result = true;
    }

    return result;
  }
Exemplo n.º 20
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::HalCore> hal_core = core.get<Ekiga::HalCore> ("hal-core");
    boost::shared_ptr<GUDevMonitor> monitor = core.get<GUDevMonitor> ("gudev");

    if (hal_core && !monitor) {

      monitor = boost::shared_ptr<GUDevMonitor> (new GUDevMonitor);

      core.add (Ekiga::ServicePtr (monitor));
      hal_core->add_manager (*monitor);
      result = true;
    }

    return result;
  }
Exemplo n.º 21
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
    boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");

    if (contact_core && call_core) {

      boost::shared_ptr<History::Source> source (new History::Source (core));
      if (core.add (source)) {

	contact_core->add_source (source);
	result = true;
      }
    }

    return result;
  }
Exemplo n.º 22
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
    boost::shared_ptr<Local::Cluster> cluster = core.get<Local::Cluster> ("local-cluster");

    if (cluster && contact_core) {

      boost::shared_ptr<Local::ContactDecorator> decorator (new Local::ContactDecorator (cluster));
      if (core.add (decorator)) {

	contact_core->add_contact_decorator (decorator);
	result = true;
      }
    }

    return result;
  }
bool
audiooutput_ptlib_init (Ekiga::ServiceCore &core,
	    int */*argc*/,
	    char **/*argv*/[])
{
  bool result = false;
  Ekiga::AudioOutputCore *audiooutput_core = NULL;

  audiooutput_core
    = dynamic_cast<Ekiga::AudioOutputCore*>(core.get ("audiooutput-core"));

  if (audiooutput_core != NULL) {

    GMAudioOutputManager_ptlib *audiooutput_manager = new GMAudioOutputManager_ptlib(core);

    audiooutput_core->add_manager (*audiooutput_manager);
    result = true;
  }

  return result;
}
Exemplo n.º 24
0
bool
hal_dbus_init (Ekiga::ServiceCore &core,
	    int */*argc*/,
	    char **/*argv*/[])
{
  bool result = false;
  Ekiga::HalCore *hal_core = NULL;

  hal_core
    = dynamic_cast<Ekiga::HalCore*>(core.get ("hal-core"));

  if (hal_core != NULL) {

    HalManager_dbus *hal_manager = new HalManager_dbus(core);

    hal_core->add_manager (*hal_manager);
    result = true;
  }

  return result;
}
bool
videooutput_dx_init (Ekiga::ServiceCore &core,
                     int */*argc*/,
                     char **/*argv*/[])
{
    bool result = false;
    Ekiga::VideoOutputCore *videooutput_core = NULL;

    videooutput_core
        = dynamic_cast<Ekiga::VideoOutputCore*>(core.get ("videooutput-core"));

    if (videooutput_core != NULL) {

        GMVideoOutputManager_dx *videooutput_manager = new GMVideoOutputManager_dx(core);

        videooutput_core->add_manager (*videooutput_manager);
        result = true;
    }

    return result;
}
Exemplo n.º 26
0
bool
gtk_frontend_init (Ekiga::ServiceCore &core,
		   int * /*argc*/,
		   char ** /*argv*/[])
{
  bool result = false;

  boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
  boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
  boost::shared_ptr<Ekiga::ChatCore> chat_core = core.get<Ekiga::ChatCore> ("chat-core");
  boost::shared_ptr<History::Source> history_source = core.get<History::Source> ("call-history-store");
  boost::shared_ptr<Opal::Bank> opal_bank = core.get<Opal::Bank> ("opal-account-store");
  boost::shared_ptr<Ekiga::Trigger> local_cluster_trigger = core.get<Ekiga::Trigger> ("local-cluster");
  boost::shared_ptr<Ekiga::PersonalDetails> details = core.get<Ekiga::PersonalDetails> ("personal-details");
  boost::shared_ptr<Ekiga::NotificationCore> notification_core = core.get<Ekiga::NotificationCore> ("notification-core");
  boost::shared_ptr<Ekiga::AccountCore> account_core = core.get<Ekiga::AccountCore> ("account-core");
  boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
  boost::shared_ptr<Ekiga::VideoOutputCore> videooutput_core = core.get<Ekiga::VideoOutputCore> ("videooutput-core");
  boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
  boost::shared_ptr<Ekiga::AudioOutputCore> audioooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
  boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");

  if (presence_core && contact_core && chat_core && history_source && opal_bank && local_cluster_trigger
      && notification_core && details && account_core && audioooutput_core && audioinput_core
      && videooutput_core && videoinput_core && call_core) {

    // BEWARE: the GtkFrontend ctor could do everything, but the status
    // icon ctor and the main window ctor use GtkFrontend, so we must
    // keep the ctor+build setup
    boost::shared_ptr<GtkFrontend> gtk_frontend (new GtkFrontend (core));
    core.add (gtk_frontend);
    gtk_frontend->build ();
    result = true;
  }
  return result;
}
Exemplo n.º 27
0
  bool try_initialize_more (Ekiga::ServiceCore& core,
			    int* /*argc*/,
			    char** /*argv*/[])
  {
    boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
    boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
    boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");
    boost::shared_ptr<Ekiga::ChatCore> chat_core = core.get<Ekiga::ChatCore> ("chat-core");
    boost::shared_ptr<Ekiga::AccountCore> account_core = core.get<Ekiga::AccountCore> ("account-core");
    boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
    boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
    boost::shared_ptr<Ekiga::AudioOutputCore> audiooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
    boost::shared_ptr<Ekiga::VideoOutputCore> videooutput_core = core.get<Ekiga::VideoOutputCore> ("videooutput-core");
    boost::shared_ptr<Ekiga::PersonalDetails> personal_details = core.get<Ekiga::PersonalDetails> ("personal-details");
    boost::shared_ptr<Bank> account_store = core.get<Bank> ("opal-account-store");
    Ekiga::ServicePtr sip_endpoint = core.get ("opal-sip-endpoint");

    if (contact_core && presence_core && call_core && chat_core
	&& account_core && audioinput_core && videoinput_core
	&& audiooutput_core && videooutput_core && personal_details
	&& !account_store && !sip_endpoint) {

      hook_ekiga_plugins_to_opal (core);

      boost::shared_ptr<CallManager> call_manager (new CallManager (core));
      core.add (call_manager);

      unsigned sip_port = gm_conf_get_int (SIP_KEY "listen_port");
      boost::shared_ptr<Sip::EndPoint> sip_manager (new Sip::EndPoint (*call_manager, core, sip_port), null_deleter ());
      core.add (sip_manager);

      call_manager->add_protocol_manager (sip_manager);
      contact_core->add_contact_decorator (sip_manager);
      presence_core->add_presentity_decorator (sip_manager);

      boost::shared_ptr<Bank> bank (new Bank (core));
      account_core->add_bank (bank);
      core.add (bank);
      sip_manager->update_bank ();
      call_manager->ready.connect (boost::bind (&Opal::Bank::call_manager_ready, &*bank));
      presence_core->add_presence_publisher (bank);
      presence_core->add_presence_fetcher (bank);


#ifdef HAVE_H323
      unsigned h323_port = gm_conf_get_int (H323_KEY "listen_port");
      boost::shared_ptr<H323::EndPoint> h323_manager (new H323::EndPoint (*call_manager, core, h323_port), null_deleter ());
      call_manager->add_protocol_manager (h323_manager);
      contact_core->add_contact_decorator (h323_manager);
      presence_core->add_presentity_decorator (h323_manager);
      core.add (h323_manager);
#endif

      call_core->add_manager (call_manager);

      new ConfBridge (*call_manager); // FIXME: isn't that leaked!?

      presence_core->add_supported_uri (&is_supported_address); //FIXME

      result = true;
    }

    return result;
  }
GMAudioInputManager_null::GMAudioInputManager_null (Ekiga::ServiceCore & _core)
:    core (_core), runtime (*(dynamic_cast<Ekiga::Runtime *> (_core.get ("runtime"))))
{
  current_state.opened = false;
}