comparison src/audacious/main.c @ 2785:182aa34ae6c4 trunk

[svn] - implement some audacious-remote functions. - implement some audacious-drct functions. - make some command line options work. (this may incur very slow startup.) - suppress warnings.
author yaz
date Tue, 22 May 2007 15:17:15 -0700
parents 8249a1248a09
children c539e972b514
comparison
equal deleted inserted replaced
2784:0a982aad6e07 2785:182aa34ae6c4
48 #include "configdb.h" 48 #include "configdb.h"
49 #include "vfs.h" 49 #include "vfs.h"
50 50
51 #ifdef USE_DBUS 51 #ifdef USE_DBUS
52 # include "dbus-service.h" 52 # include "dbus-service.h"
53 # include "audctrl.h"
53 #endif 54 #endif
54 55
55 #include "dnd.h" 56 #include "dnd.h"
56 #include "effect.h" 57 #include "effect.h"
57 #include "ui_equalizer.h" 58 #include "ui_equalizer.h"
894 static void 895 static void
895 handle_cmd_line_options(BmpCmdLineOpt * options, 896 handle_cmd_line_options(BmpCmdLineOpt * options,
896 gboolean remote) 897 gboolean remote)
897 { 898 {
898 gchar **filenames = options->filenames; 899 gchar **filenames = options->filenames;
899 #ifdef HAVE_DBUS 900 #ifdef USE_DBUS
900 // DBusGProxy *session = audacious_get_dbus_proxy(); 901 DBusGProxy *session = audacious_get_dbus_proxy();
902 printf("session = %p\n", session);
901 #endif 903 #endif
902 904
903 if (options->version) 905 if (options->version)
904 { 906 {
905 dump_version(); 907 dump_version();
906 exit(EXIT_SUCCESS); 908 exit(EXIT_SUCCESS);
907 } 909 }
908 910
909 #if 0 911 #if 1
910 if (filenames != NULL) 912 if (filenames != NULL)
911 { 913 {
912 gint pos = 0; 914 gint pos = 0;
913 gint i = 0; 915 gint i = 0;
914 GList *fns = NULL; 916 GList *fns = NULL;
993 audacious_remote_activate(session); 995 audacious_remote_activate(session);
994 #endif 996 #endif
995 997
996 if (options->playcd) 998 if (options->playcd)
997 play_medium(); 999 play_medium();
1000
1001 printf("remote = %d\n", remote);
1002 {
1003 gboolean is_running = audacious_remote_is_running(session);
1004 printf("is_running %d\n", is_running);
1005 if (is_running)
1006 exit(EXIT_SUCCESS);
1007 }
998 } 1008 }
999 1009
1000 static void 1010 static void
1001 bmp_setup_logger(void) 1011 bmp_setup_logger(void)
1002 { 1012 {