Allow explicit building of local applets. Shrinked buf size for numbers

This commit is contained in:
Sanel Zukan 2011-10-27 15:11:11 +00:00
parent c97c675153
commit 9f349dae04
3 changed files with 4 additions and 2 deletions

View File

@ -11,6 +11,7 @@
SubDir TOP ede-panel ;
EdeProgram ede-panel : Panel.cpp AppletManager.cpp ede-panel.cpp ;
#ObjectC++Flags Panel.cpp : -DEDE_PANEL_LOCAL_APPLETS ;
if $(OS) != "SOLARIS" {
# also must use this flag (on anything but Solaris) or program will crash

View File

@ -404,6 +404,7 @@ int Panel::handle(int e) {
}
void Panel::load_applets(void) {
#ifndef EDE_PANEL_LOCAL_APPLETS
/* FIXME: hardcoded order */
static const char *applets[] = {
"start_menu.so",
@ -429,7 +430,7 @@ void Panel::load_applets(void) {
}
mgr.fill_group(this);
#if 0
#else
mgr.load("./applets/start-menu/start_menu.so");
mgr.load("./applets/quick-launch/quick_launch.so");
mgr.load("./applets/pager/pager.so");

View File

@ -12,7 +12,7 @@ PagerButton::~PagerButton() {
void PagerButton::set_workspace_label(int l) {
wlabel = l;
char buf[16];
char buf[6];
snprintf(buf, sizeof(buf), "%i", l);
copy_label(buf);
}