mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-20 12:58:08 +01:00
WScreen argument removed in get_generic_value()
The argument "src" is removed in the function get_generic_value() because it is not used. The function wDefaultGetIconFile() is moved close to wDefaultGetStartWorkspace() because both are similar.
This commit is contained in:
committed by
Carlos R. Mafra
parent
910a851f35
commit
32fe186c54
@@ -317,7 +317,7 @@ wDefaultFillAttributes(WScreen * scr, char *instance, char *class,
|
||||
WMPLSetCaseSensitive(False);
|
||||
}
|
||||
|
||||
static WMPropList *get_generic_value(WScreen *scr, char *instance, char *class,
|
||||
static WMPropList *get_generic_value(char *instance, char *class,
|
||||
WMPropList *option, Bool noDefault)
|
||||
{
|
||||
WMPropList *value, *key, *dict;
|
||||
@@ -378,28 +378,6 @@ static WMPropList *get_generic_value(WScreen *scr, char *instance, char *class,
|
||||
return value;
|
||||
}
|
||||
|
||||
/* Get the name of the Icon File. If noDefault is False, then, default value included */
|
||||
char *wDefaultGetIconFile(WScreen * scr, char *instance, char *class, Bool noDefault)
|
||||
{
|
||||
WMPropList *value;
|
||||
char *tmp;
|
||||
|
||||
if (!ANoTitlebar)
|
||||
init_wdefaults(scr);
|
||||
|
||||
if (!WDWindowAttributes->dictionary)
|
||||
return NULL;
|
||||
|
||||
value = get_generic_value(scr, instance, class, AIcon, noDefault);
|
||||
|
||||
if (!value)
|
||||
return NULL;
|
||||
|
||||
tmp = getString(AIcon, value);
|
||||
|
||||
return tmp;
|
||||
}
|
||||
|
||||
RImage *wDefaultGetImage(WScreen * scr, char *winstance, char *wclass, int max_size)
|
||||
{
|
||||
char *file_name;
|
||||
@@ -442,7 +420,7 @@ int wDefaultGetStartWorkspace(WScreen * scr, char *instance, char *class)
|
||||
if (!WDWindowAttributes->dictionary)
|
||||
return -1;
|
||||
|
||||
value = get_generic_value(scr, instance, class, AStartWorkspace, False);
|
||||
value = get_generic_value(instance, class, AStartWorkspace, False);
|
||||
|
||||
if (!value)
|
||||
return -1;
|
||||
@@ -458,6 +436,28 @@ int wDefaultGetStartWorkspace(WScreen * scr, char *instance, char *class)
|
||||
return w;
|
||||
}
|
||||
|
||||
/* Get the name of the Icon File. If noDefault is False, then, default value included */
|
||||
char *wDefaultGetIconFile(WScreen *scr, char *instance, char *class, Bool noDefault)
|
||||
{
|
||||
WMPropList *value;
|
||||
char *tmp;
|
||||
|
||||
if (!ANoTitlebar)
|
||||
init_wdefaults(scr);
|
||||
|
||||
if (!WDWindowAttributes->dictionary)
|
||||
return NULL;
|
||||
|
||||
value = get_generic_value(instance, class, AIcon, noDefault);
|
||||
|
||||
if (!value)
|
||||
return NULL;
|
||||
|
||||
tmp = getString(AIcon, value);
|
||||
|
||||
return tmp;
|
||||
}
|
||||
|
||||
void wDefaultChangeIcon(WScreen * scr, char *instance, char *class, char *file)
|
||||
{
|
||||
WDDomain *db = WDWindowAttributes;
|
||||
|
||||
Reference in New Issue
Block a user