SF.net SVN: geany: [2289] trunk
eht16 at users.sourceforge.net
eht16 at xxxxx
Wed Feb 27 14:23:21 UTC 2008
Revision: 2289
http://geany.svn.sourceforge.net/geany/?rev=2289&view=rev
Author: eht16
Date: 2008-02-27 06:23:13 -0800 (Wed, 27 Feb 2008)
Log Message:
-----------
Fix a few more compiler warnings (type conversion warnings).
Modified Paths:
--------------
trunk/ChangeLog
trunk/src/document.c
trunk/src/utils.c
trunk/src/utils.h
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2008-02-27 14:21:34 UTC (rev 2288)
+++ trunk/ChangeLog 2008-02-27 14:23:13 UTC (rev 2289)
@@ -2,6 +2,10 @@
* plugins/*, scintilla/*, src/*, tagmanager/*:
Replace all C++-style comments with usual C-like multi-line comments.
+ * src/keybindings.c: Fix ignoring of some keybindings when caps lock is
+ active (introduced in r2253).
+ * src/document.c, src/utils.c, src/utils.h:
+ Fix a few more compiler warnings (type conversion warnings).
2008-02-26 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
Modified: trunk/src/document.c
===================================================================
--- trunk/src/document.c 2008-02-27 14:21:34 UTC (rev 2288)
+++ trunk/src/document.c 2008-02-27 14:23:13 UTC (rev 2289)
@@ -1127,7 +1127,7 @@
if (length < 0)
length = strlen(data);
- switch (utils_get_line_endings((gchar*) data, length))
+ switch (utils_get_line_endings(data, length))
{
case SC_EOL_CR: list = g_strsplit(data, "\r", 0); break;
case SC_EOL_CRLF: list = g_strsplit(data, "\r\n", 0); break;
Modified: trunk/src/utils.c
===================================================================
--- trunk/src/utils.c 2008-02-27 14:21:34 UTC (rev 2288)
+++ trunk/src/utils.c 2008-02-27 14:23:13 UTC (rev 2289)
@@ -94,7 +94,7 @@
/* taken from anjuta, to determine the EOL mode of the file */
-gint utils_get_line_endings(gchar* buffer, glong size)
+gint utils_get_line_endings(const gchar* buffer, glong size)
{
gint i;
guint cr, lf, crlf, max_mode;
@@ -941,7 +941,7 @@
}
-gchar *utils_get_initials(gchar *name)
+gchar *utils_get_initials(const gchar *name)
{
gint i = 1, j = 1;
gchar *initials = g_malloc0(5);
@@ -1542,7 +1542,7 @@
* The first argument is nothing special.
* The list must be ended with NULL.
* If first is NULL, NULL is returned. */
-gchar **utils_strv_new(gchar *first, ...)
+gchar **utils_strv_new(const gchar *first, ...)
{
gsize strvlen, i;
va_list args;
@@ -1734,6 +1734,7 @@
/* check only letters and stop once the first non-capital was found */
if (g_unichar_isalpha(c) && g_unichar_isupper(c))
return TRUE;
+ /** FIXME don't write a const string */
str = g_utf8_next_char(str);
}
return FALSE;
Modified: trunk/src/utils.h
===================================================================
--- trunk/src/utils.h 2008-02-27 14:21:34 UTC (rev 2288)
+++ trunk/src/utils.h 2008-02-27 14:23:13 UTC (rev 2289)
@@ -48,7 +48,7 @@
void utils_start_browser(const gchar *uri);
-gint utils_get_line_endings(gchar* buffer, glong size);
+gint utils_get_line_endings(const gchar* buffer, glong size);
gboolean utils_isbrace(gchar c, gboolean include_angles);
@@ -90,11 +90,11 @@
gchar *utils_str_replace(gchar *haystack, const gchar *needle, const gchar *replacement);
-gint utils_strpos(const gchar* haystack, const gchar * needle);
+gint utils_strpos(const gchar* haystack, const gchar *needle);
gchar *utils_get_date_time(const gchar *format, time_t *time_to_use);
-gchar *utils_get_initials(gchar *name);
+gchar *utils_get_initials(const gchar *name);
gboolean utils_get_setting_boolean(GKeyFile *config, const gchar *section, const gchar *key, const gboolean default_value);
@@ -136,7 +136,7 @@
void utils_free_pointers(gpointer first, ...) G_GNUC_NULL_TERMINATED;
-gchar **utils_strv_new(gchar *first, ...) G_GNUC_NULL_TERMINATED;
+gchar **utils_strv_new(const gchar *first, ...) G_GNUC_NULL_TERMINATED;
gint utils_mkdir(const gchar *path, gboolean create_parent_dirs);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Commits
mailing list