summaryrefslogtreecommitdiffstats
path: root/src/Applet
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2009-12-10 13:10:43 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2009-12-10 13:10:43 +0100
commitfc2c5e2f02e6da00e27d68a83277a61efdcc9f83 (patch)
tree29578e2e041586f63d6aff5f6ec16db941ea2ef8 /src/Applet
parent86930df464c57f84a461e4a98e5f813bff73952d (diff)
downloadabrt-fc2c5e2f02e6da00e27d68a83277a61efdcc9f83.tar.gz
abrt-fc2c5e2f02e6da00e27d68a83277a61efdcc9f83.tar.xz
abrt-fc2c5e2f02e6da00e27d68a83277a61efdcc9f83.zip
style fixes, no code changes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'src/Applet')
-rw-r--r--src/Applet/Applet.cpp2
-rw-r--r--src/Applet/CCApplet.cpp18
-rw-r--r--src/Applet/CCApplet.h2
3 files changed, 11 insertions, 11 deletions
diff --git a/src/Applet/Applet.cpp b/src/Applet/Applet.cpp
index 46278c62..14707697 100644
--- a/src/Applet/Applet.cpp
+++ b/src/Applet/Applet.cpp
@@ -135,7 +135,7 @@ static void NameOwnerChanged(DBusMessage* signal)
}
// hide icon if it's visible - as NM and don't show it, if it's not
- if(!new_owner[0])
+ if (!new_owner[0])
applet->HideIcon();
}
diff --git a/src/Applet/CCApplet.cpp b/src/Applet/CCApplet.cpp
index e6b89d2f..5d13ab87 100644
--- a/src/Applet/CCApplet.cpp
+++ b/src/Applet/CCApplet.cpp
@@ -114,7 +114,7 @@ CApplet::CApplet()
m_iAnimationStage = ICON_DEFAULT;
m_bIconsLoaded = load_icons();
/* - animation - */
- if(m_bIconsLoaded == true)
+ if (m_bIconsLoaded == true)
{
m_pStatusIcon = gtk_status_icon_new_from_pixbuf(icon_stages_buff[ICON_DEFAULT]);
}
@@ -244,7 +244,7 @@ void CApplet::ShowIcon()
{
gtk_status_icon_set_visible(m_pStatusIcon, true);
/* only animate if all icons are loaded, use the "gtk-warning" instead */
- if(m_bIconsLoaded)
+ if (m_bIconsLoaded)
animate_icon();
}
@@ -300,13 +300,13 @@ void CApplet::Enable(const char *reason)
gboolean CApplet::update_icon(void *user_data)
{
CApplet* applet = (CApplet*)user_data;
- if(applet->m_pStatusIcon && applet->m_iAnimationStage < ICON_STAGE_LAST){
+ if (applet->m_pStatusIcon && applet->m_iAnimationStage < ICON_STAGE_LAST) {
gtk_status_icon_set_from_pixbuf(applet->m_pStatusIcon,
applet->icon_stages_buff[applet->m_iAnimationStage++]);
}
else
error_msg("icon is null");
- if(applet->m_iAnimationStage == ICON_STAGE_LAST){
+ if (applet->m_iAnimationStage == ICON_STAGE_LAST) {
applet->m_iAnimationStage = 0;
}
if (--applet->m_iAnimCountdown == 0) {
@@ -317,7 +317,7 @@ gboolean CApplet::update_icon(void *user_data)
void CApplet::animate_icon()
{
- if(m_iAnimator == 0)
+ if (m_iAnimator == 0)
{
m_iAnimator = g_timeout_add(100, update_icon, this);
m_iAnimCountdown = 10 * 60; /* 60 sec */
@@ -327,7 +327,7 @@ void CApplet::animate_icon()
void CApplet::stop_animate_icon()
{
/* animator should be 0 if icons are not loaded, so this should be safe */
- if(m_iAnimator != 0){
+ if (m_iAnimator != 0) {
g_source_remove(m_iAnimator);
gtk_status_icon_set_from_pixbuf(m_pStatusIcon, icon_stages_buff[ICON_DEFAULT]);
m_iAnimator = 0;
@@ -337,13 +337,13 @@ void CApplet::stop_animate_icon()
bool CApplet::load_icons()
{
int stage;
- for(stage = ICON_DEFAULT; stage < ICON_STAGE_LAST; stage++)
+ for (stage = ICON_DEFAULT; stage < ICON_STAGE_LAST; stage++)
{
char name[sizeof(ICON_DIR"/abrt%02d.png")];
GError *error = NULL;
- if(snprintf(name, sizeof(ICON_DIR"/abrt%02d.png"),ICON_DIR"/abrt%02d.png", stage) > 0){
+ if (snprintf(name, sizeof(ICON_DIR"/abrt%02d.png"), ICON_DIR"/abrt%02d.png", stage) > 0) {
icon_stages_buff[stage] = gdk_pixbuf_new_from_file(name, &error);
- if(error != NULL){
+ if (error != NULL) {
error_msg("Can't load pixbuf from %s, animation is disabled!", name);
return false;
}
diff --git a/src/Applet/CCApplet.h b/src/Applet/CCApplet.h
index 15ac2f7f..48dbabcc 100644
--- a/src/Applet/CCApplet.h
+++ b/src/Applet/CCApplet.h
@@ -77,7 +77,7 @@ class CApplet
protected:
//@@TODO applet menus
- static void OnAppletActivate_CB(GtkStatusIcon *status_icon,gpointer user_data);
+ static void OnAppletActivate_CB(GtkStatusIcon *status_icon, gpointer user_data);
static void OnMenuPopup_cb(GtkStatusIcon *status_icon,
guint button,
guint activate_time,