diff --git a/src/dialogs.c b/src/dialogs.c index 5fd96ef25..417a6c61d 100644 --- a/src/dialogs.c +++ b/src/dialogs.c @@ -22,6 +22,7 @@ #include +#include #include "dialogs.h" @@ -29,7 +30,10 @@ #include "document.h" #include "win32.h" #include "about.h" - +#include "sciwrappers.h" +#include "support.h" +#include "interface.h" +#include "utils.h" /* This shows the file selection dialog to open a file. */ void dialogs_show_open_file () @@ -143,8 +147,7 @@ gboolean dialogs_show_not_found(const gchar *text) else return FALSE; #else dialog = gtk_message_dialog_new(GTK_WINDOW(app->window), GTK_DIALOG_DESTROY_WITH_PARENT, - GTK_MESSAGE_QUESTION, GTK_BUTTONS_YES_NO, NULL); - gtk_message_dialog_set_markup(GTK_MESSAGE_DIALOG(dialog), string); + GTK_MESSAGE_QUESTION, GTK_BUTTONS_YES_NO, "%s", string); g_free(string); ret = gtk_dialog_run(GTK_DIALOG (dialog)); gtk_widget_destroy(dialog); diff --git a/src/dialogs.h b/src/dialogs.h index a9d9799c3..e5befaae1 100644 --- a/src/dialogs.h +++ b/src/dialogs.h @@ -26,10 +26,6 @@ #ifndef GEANY_DIALOGS_H #define GEANY_DIALOGS_H 1 -#include "support.h" -#include "interface.h" -#include "utils.h" - /* This shows the file selection dialog to open a file. */ void dialogs_show_open_file (void); diff --git a/src/document.h b/src/document.h index 4272ba8f7..ca6649ce9 100644 --- a/src/document.h +++ b/src/document.h @@ -17,18 +17,13 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * + * $Id$ */ #ifndef GEANY_DOCUMENT_H #define GEANY_DOCUMENT_H 1 -#include "geany.h" -#include "callbacks.h" -#include "sciwrappers.h" -#include "sci_cb.h" -#include "dialogs.h" -#include "msgwindow.h" /* returns the index of the notebook page which has the given filename */ gint document_find_by_filename(const gchar*); diff --git a/src/encodings.h b/src/encodings.h index 3b5b9329f..a581058d2 100644 --- a/src/encodings.h +++ b/src/encodings.h @@ -17,6 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * + * $Id$ */ @@ -31,8 +32,6 @@ #ifndef GEANY_ENCODINGS_H #define GEANY_ENCODINGS_H -#include - typedef struct _GeanyEncoding GeanyEncoding; const GeanyEncoding* encoding_get_from_charset(const gchar *charset); diff --git a/src/sci_cb.c b/src/sci_cb.c index 47229666e..88d7a5748 100644 --- a/src/sci_cb.c +++ b/src/sci_cb.c @@ -22,8 +22,14 @@ #include -#include "sci_cb.h" +#include +#include "geany.h" + +#include "sci_cb.h" +#include "document.h" +#include "sciwrappers.h" +#include "utils.h" static gint link_start, link_end, style; static gchar indent[100]; diff --git a/src/sci_cb.h b/src/sci_cb.h index 89ed98dcf..0b72adb5e 100644 --- a/src/sci_cb.h +++ b/src/sci_cb.h @@ -23,12 +23,6 @@ #define GEANY_SCI_CB_H 1 -#include "geany.h" - -#include "document.h" -#include "sciwrappers.h" -#include "utils.h" - // callback func called by all editors when a signals arises void on_editor_notification(GtkWidget* editor, gint scn, gpointer lscn, gpointer user_data); diff --git a/src/sciwrappers.c b/src/sciwrappers.c index 8fa7f82ef..15d156792 100644 --- a/src/sciwrappers.c +++ b/src/sciwrappers.c @@ -20,6 +20,9 @@ * $Id$ */ +#include + +#include "geany.h" #include "sciwrappers.h" #include "utils.h" diff --git a/src/sciwrappers.h b/src/sciwrappers.h index 8c4acd8f4..861326916 100644 --- a/src/sciwrappers.h +++ b/src/sciwrappers.h @@ -20,31 +20,17 @@ * $Id$ */ - -#include -#include -#include -#include -#include -#include - -#ifndef WIN32 -# include -# include -#endif +#ifndef GEANY_SCIWRAPPERS_H +#define GEANY_SCIWRAPPERS_H 1 #include "geany.h" -#include "interface.h" -#include "support.h" - void sci_set_line_numbers (ScintillaObject* sci, gboolean set, gint extra_width); void sci_set_mark_long_lines (ScintillaObject* sci, gint column, const gchar *color); void sci_set_text (ScintillaObject* sci, const gchar* text); void sci_add_text (ScintillaObject* sci, const gchar* text); void sci_add_text_buffer (ScintillaObject* sci, const gchar* text, gint len); - gboolean sci_can_redo (ScintillaObject* sci); gboolean sci_can_undo (ScintillaObject* sci); gboolean sci_can_copy (ScintillaObject* sci); @@ -157,3 +143,5 @@ gboolean sci_get_readonly (ScintillaObject * sci); gint sci_get_zoom (ScintillaObject * sci); void sci_cmd (ScintillaObject * sci, gint cmd); gint sci_get_current_line (ScintillaObject * sci, gint pos); + +#endif diff --git a/src/vte.h b/src/vte.h index b20428861..7b037dcf4 100644 --- a/src/vte.h +++ b/src/vte.h @@ -24,8 +24,6 @@ #ifndef GEANY_VTE_H #define GEANY_VTE_H 1 -#include - void vte_init(void); diff --git a/src/win32.c b/src/win32.c index 7b1f052e1..96d1fd940 100644 --- a/src/win32.c +++ b/src/win32.c @@ -17,15 +17,21 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * + * $Id$ */ // special functions for the win32 platform -#include "win32.h" +#include "geany.h" #ifdef GEANY_WIN32 +#include "win32.h" + +#include "document.h" +#include "support.h" + //static gchar appfontname[128] = "tahoma 8"; /* fallback value */ static gchar *filters; diff --git a/src/win32.h b/src/win32.h index 38eac9188..2d1cbed1b 100644 --- a/src/win32.h +++ b/src/win32.h @@ -17,16 +17,13 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * + * $Id$ */ -#include "geany.h" - #ifdef GEANY_WIN32 -#include "document.h" -#include "support.h" /*void set_app_font(const char *fontname);