commit 5a8868382bf45a474e748f3311a45ec656860c55
Author: phantomjinx <[email protected]>
Date: Thu Dec 24 16:01:41 2009 +0000
Minor fixes post-merge
directories.c
- Comment out debug_print_directories function
file_itunesdb.c
- Replace gtkpod_window with gtkpod_app
misc.c
- Incorrect merge of gtkpod_init code into get_user_string function
src/directories.c | 6 ++++-
src/file_itunesdb.c | 4 +-
src/misc.c | 61 +++-----------------------------------------------
3 files changed, 11 insertions(+), 60 deletions(-)
---
diff --git a/src/directories.c b/src/directories.c
index cb5e8f3..9d4a570 100644
--- a/src/directories.c
+++ b/src/directories.c
@@ -33,7 +33,9 @@
static int USING_LOCAL = 0;
static gchar * init_dir(char *argv[], gchar *filename, gchar *installdir);
+#if LOCALDEBUG
static void debug_print_directories();
+#endif
static gchar *datadir = NULL;
static gchar *icondir = NULL;
@@ -53,6 +55,7 @@ void init_directories(char *argv[]) {
// debug_print_directories();
}
+#if LOCALDEBUG
static void debug_print_directories() {
g_printf("data directory: %s\n", get_data_dir());
g_printf("ui directory: %s\n", get_ui_dir());
@@ -60,10 +63,11 @@ static void debug_print_directories() {
g_printf("icon directory: %s\n", get_icon_dir());
g_printf("plugin directory: %s\n", get_plugin_dir());
}
+#endif
static gchar * init_dir(char *argv[], gchar *localdir, gchar *fullinstalldir) {
gchar *progname;
- gchar *newdir;
+ gchar *newdir = NULL;
progname = g_find_program_in_path(argv[0]);
if (progname) {
diff --git a/src/file_itunesdb.c b/src/file_itunesdb.c
index 9eb5d53..57cd6ea 100644
--- a/src/file_itunesdb.c
+++ b/src/file_itunesdb.c
@@ -930,7 +930,7 @@ gboolean gp_eject_ipod(iTunesDB *itdb) {
* return value: TRUE on succes, FALSE when an error occurred.
*/
gboolean gp_save_itdb(iTunesDB *itdb) {
- Playlist *pl;
+// Playlist *pl;
gboolean success;
g_return_val_if_fail (itdb, FALSE);
@@ -1562,7 +1562,7 @@ static gboolean transfer_tracks(iTunesDB *itdb,
TransferData *td) {
to_transfer_num);
dialog = gtk_message_dialog_new (
- GTK_WINDOW (gtkpod_window),
+ GTK_WINDOW (gtkpod_app),
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_WARNING,
GTK_BUTTONS_OK,
diff --git a/src/misc.c b/src/misc.c
index be46f93..1e4bca1 100644
--- a/src/misc.c
+++ b/src/misc.c
@@ -1861,64 +1861,11 @@ gchar *get_user_string (gchar *title, gchar *message,
gchar *dflt,
accept_button ? accept_button : GTK_STOCK_OK,
GTK_RESPONSE_OK,
NULL);
- progname = g_find_program_in_path (argv[0]);
- if (progname)
- {
- static const gchar *SEPsrcSEPgtkpod = G_DIR_SEPARATOR_S "src"
G_DIR_SEPARATOR_S "gtkpod";
-
- if (!g_path_is_absolute (progname))
- {
- gchar *cur_dir = g_get_current_dir ();
- gchar *prog_absolute;
-
- if (g_str_has_prefix (progname, "." G_DIR_SEPARATOR_S))
- prog_absolute = g_build_filename (cur_dir,progname+2,NULL);
- else
- prog_absolute = g_build_filename (cur_dir,progname,NULL);
-
- g_free (progname);
- g_free (cur_dir);
- progname = prog_absolute;
- }
-
- if (g_str_has_suffix (progname, SEPsrcSEPgtkpod))
- {
- gchar *suffix = g_strrstr (progname, SEPsrcSEPgtkpod);
+ temp = g_markup_printf_escaped ("<span weight='bold'
size='larger'>%s</span>\n\n%s", title, message);
+ gtk_label_set_markup (GTK_LABEL (label), temp);
+ g_free (temp);
- if (suffix)
- {
- *suffix = 0;
- xml_file = g_build_filename (progname, "data", "gtkpod.glade",
NULL);
- }
- }
-
- if (!xml_file)
- {
- gchar *prog_path = g_path_get_dirname (progname);
- gchar *cmake_file = g_build_filename (prog_path, "CMakeCache.txt",
NULL);
-
- if (g_file_test (cmake_file, G_FILE_TEST_EXISTS))
- {
- gchar *source_root = g_path_get_dirname (prog_path);
- xml_file = g_build_filename(source_root, "data", "gtkpod.glade",
NULL);
- g_free (source_root);
- }
-
- g_free (cmake_file);
- g_free (prog_path);
- }
-
- g_free (progname);
-
- if (xml_file && !g_file_test (xml_file, G_FILE_TEST_EXISTS))
- {
- g_free (xml_file);
- xml_file = NULL;
- }
- }
- if (!xml_file)
- xml_file = g_build_filename (PACKAGE_DATA_DIR, PACKAGE, "data",
"gtkpod.glade", NULL);
- else
+ if (dflt)
{
gtk_entry_set_text (GTK_ENTRY (entry), dflt);
gtk_editable_select_region (GTK_EDITABLE (entry), 0, -1);
------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev
_______________________________________________
gtkpod-cvs2 mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2