empathy r563 - trunk/libempathy-gtk



Author: xclaesse
Date: Wed Jan 16 15:32:35 2008
New Revision: 563
URL: http://svn.gnome.org/viewvc/empathy?rev=563&view=rev

Log:
Rename BlockType to EMPATHY_CHAT_VIEW_BLOCK to respect namespace


Modified:
   trunk/libempathy-gtk/empathy-chat-view.c
   trunk/libempathy-gtk/empathy-chat-view.h
   trunk/libempathy-gtk/empathy-theme-boxes.c

Modified: trunk/libempathy-gtk/empathy-chat-view.c
==============================================================================
--- trunk/libempathy-gtk/empathy-chat-view.c	(original)
+++ trunk/libempathy-gtk/empathy-chat-view.c	Wed Jan 16 15:32:35 2008
@@ -70,7 +70,7 @@
 	EmpathyTheme   *theme;
 
 	time_t         last_timestamp;
-	BlockType      last_block_type;
+	EmpathyChatViewBlock last_block_type;
 
 	gboolean       allow_scrolling;
 	guint          scroll_timeout;
@@ -158,7 +158,7 @@
 
 	priv->buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view));
 
-	priv->last_block_type = BLOCK_TYPE_NONE;
+	priv->last_block_type = EMPATHY_CHAT_VIEW_BLOCK_NONE;
 	priv->last_timestamp = 0;
 
 	priv->allow_scrolling = TRUE;
@@ -638,7 +638,7 @@
 
 	priv = GET_PRIV (view);
 
-	priv->last_block_type = BLOCK_TYPE_NONE;
+	priv->last_block_type = EMPATHY_CHAT_VIEW_BLOCK_NONE;
 
 	empathy_conf_get_bool (empathy_conf_get (),
 			      EMPATHY_PREFS_CHAT_THEME_CHAT_ROOM,
@@ -821,7 +821,7 @@
 		empathy_chat_view_scroll_down (view);
 	}
 
-	priv->last_block_type = BLOCK_TYPE_EVENT;
+	priv->last_block_type = EMPATHY_CHAT_VIEW_BLOCK_EVENT;
 }
 
 void
@@ -891,7 +891,7 @@
 		empathy_chat_view_scroll_down (view);
 	}
 
-	priv->last_block_type = BLOCK_TYPE_INVITE;
+	priv->last_block_type = EMPATHY_CHAT_VIEW_BLOCK_INVITE;
 }
 
 void
@@ -996,7 +996,7 @@
 	 */
 	priv = GET_PRIV (view);
 
-	priv->last_block_type = BLOCK_TYPE_NONE;
+	priv->last_block_type = EMPATHY_CHAT_VIEW_BLOCK_NONE;
 	priv->last_timestamp = 0;
 }
 
@@ -1512,7 +1512,7 @@
 	priv->last_timestamp = timestamp;
 }
 
-BlockType
+EmpathyChatViewBlock
 empathy_chat_view_get_last_block_type (EmpathyChatView *view)
 {
 	EmpathyChatViewPriv *priv;
@@ -1525,8 +1525,8 @@
 }
 
 void
-empathy_chat_view_set_last_block_type (EmpathyChatView *view, 
-				      BlockType       block_type)
+empathy_chat_view_set_last_block_type (EmpathyChatView      *view, 
+				       EmpathyChatViewBlock  block_type)
 {
 	EmpathyChatViewPriv *priv;
 

Modified: trunk/libempathy-gtk/empathy-chat-view.h
==============================================================================
--- trunk/libempathy-gtk/empathy-chat-view.h	(original)
+++ trunk/libempathy-gtk/empathy-chat-view.h	Wed Jan 16 15:32:35 2008
@@ -54,13 +54,13 @@
 };
 
 typedef enum {
-	BLOCK_TYPE_NONE,
-	BLOCK_TYPE_SELF,
-	BLOCK_TYPE_OTHER,
-	BLOCK_TYPE_EVENT,
-	BLOCK_TYPE_TIME,
-	BLOCK_TYPE_INVITE
-} BlockType;
+	EMPATHY_CHAT_VIEW_BLOCK_NONE,
+	EMPATHY_CHAT_VIEW_BLOCK_SELF,
+	EMPATHY_CHAT_VIEW_BLOCK_OTHER,
+	EMPATHY_CHAT_VIEW_BLOCK_EVENT,
+	EMPATHY_CHAT_VIEW_BLOCK_TIME,
+	EMPATHY_CHAT_VIEW_BLOCK_INVITE
+} EmpathyChatViewBlock;
 
 GType            empathy_chat_view_get_type             (void) G_GNUC_CONST;
 EmpathyChatView *empathy_chat_view_new                  (void);
@@ -106,9 +106,9 @@
 time_t           empathy_chat_view_get_last_timestamp   (EmpathyChatView *view);
 void             empathy_chat_view_set_last_timestamp   (EmpathyChatView *view,
 							 time_t           timestamp);
-BlockType        empathy_chat_view_get_last_block_type  (EmpathyChatView *view);
+EmpathyChatViewBlock empathy_chat_view_get_last_block_type  (EmpathyChatView *view);
 void             empathy_chat_view_set_last_block_type  (EmpathyChatView *view, 
-							 BlockType        block_type);
+							 EmpathyChatViewBlock block_type);
 EmpathyContact * empathy_chat_view_get_last_contact     (EmpathyChatView *view);
 void             empathy_chat_view_set_last_contact     (EmpathyChatView *view,
 							 EmpathyContact  *contact);

Modified: trunk/libempathy-gtk/empathy-theme-boxes.c
==============================================================================
--- trunk/libempathy-gtk/empathy-theme-boxes.c	(original)
+++ trunk/libempathy-gtk/empathy-theme-boxes.c	Wed Jan 16 15:32:35 2008
@@ -559,16 +559,16 @@
 	/* Only insert a header if the previously inserted block is not the same
 	 * as this one. This catches all the different cases:
 	 */
-	if (empathy_chat_view_get_last_block_type (view) != BLOCK_TYPE_SELF &&
-	    empathy_chat_view_get_last_block_type (view) != BLOCK_TYPE_OTHER) {
+	if (empathy_chat_view_get_last_block_type (view) != EMPATHY_CHAT_VIEW_BLOCK_SELF &&
+	    empathy_chat_view_get_last_block_type (view) != EMPATHY_CHAT_VIEW_BLOCK_OTHER) {
 		header = TRUE;
 	}
 	else if (from_self &&
-		 empathy_chat_view_get_last_block_type (view) == BLOCK_TYPE_OTHER) {
+		 empathy_chat_view_get_last_block_type (view) == EMPATHY_CHAT_VIEW_BLOCK_OTHER) {
 		header = TRUE;
 	}
 	else if (!from_self && 
-		 empathy_chat_view_get_last_block_type (view) == BLOCK_TYPE_SELF) {
+		 empathy_chat_view_get_last_block_type (view) == EMPATHY_CHAT_VIEW_BLOCK_SELF) {
 		header = TRUE;
 	}
 	else if (!from_self &&
@@ -710,10 +710,10 @@
 	}
 	
 	if (empathy_contact_is_user (sender)) {
-		empathy_chat_view_set_last_block_type (view, BLOCK_TYPE_SELF);
+		empathy_chat_view_set_last_block_type (view, EMPATHY_CHAT_VIEW_BLOCK_SELF);
 		empathy_chat_view_set_last_contact (view, NULL);
 	} else {
-		empathy_chat_view_set_last_block_type (view, BLOCK_TYPE_OTHER);
+		empathy_chat_view_set_last_block_type (view, EMPATHY_CHAT_VIEW_BLOCK_OTHER);
 		empathy_chat_view_set_last_contact (view, sender);
 	}
 }
@@ -741,7 +741,7 @@
 						  NULL);
 	g_free (msg);
 
-	empathy_chat_view_set_last_block_type (view, BLOCK_TYPE_EVENT);
+	empathy_chat_view_set_last_block_type (view, EMPATHY_CHAT_VIEW_BLOCK_EVENT);
 }
 
 static void
@@ -804,7 +804,7 @@
 							  "fancy-time",
 							  NULL);
 
-		empathy_chat_view_set_last_block_type (view, BLOCK_TYPE_TIME);
+		empathy_chat_view_set_last_block_type (view, EMPATHY_CHAT_VIEW_BLOCK_TIME);
 		empathy_chat_view_set_last_timestamp (view, timestamp);
 	}
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]