-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add helpline API implementation to GTK front-end. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Acked-by: Pekka Enberg <penberg@kernel.org> Cc: Ingo Molnar <mingo@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1345104894-14205-3-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
- Loading branch information
Namhyung Kim
authored and
Arnaldo Carvalho de Melo
committed
Aug 17, 2012
1 parent
e6e9046
commit 4bb1646
Showing
4 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#include "gtk.h" | ||
#include "../helpline.h" | ||
|
||
static void gtk_helpline_pop(void) | ||
{ | ||
if (!perf_gtk__is_active_context(pgctx)) | ||
return; | ||
|
||
gtk_statusbar_pop(GTK_STATUSBAR(pgctx->statbar), | ||
pgctx->statbar_ctx_id); | ||
} | ||
|
||
static void gtk_helpline_push(const char *msg) | ||
{ | ||
if (!perf_gtk__is_active_context(pgctx)) | ||
return; | ||
|
||
gtk_statusbar_push(GTK_STATUSBAR(pgctx->statbar), | ||
pgctx->statbar_ctx_id, msg); | ||
} | ||
|
||
static struct ui_helpline gtk_helpline_fns = { | ||
.pop = gtk_helpline_pop, | ||
.push = gtk_helpline_push, | ||
}; | ||
|
||
void perf_gtk__init_helpline(void) | ||
{ | ||
helpline_fns = >k_helpline_fns; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters