Corrected the 'flush' misspelling to the correct 'flash' in code & documentation, but preserving the old 'FlushMenu' built-in command and specifying that is depricated in the manual page. Issue #46

This commit is contained in:
Morgan Aldridge
2024-08-25 13:42:39 -04:00
parent b48fe824dd
commit d0ab867521
5 changed files with 22 additions and 11 deletions
+5 -1
View File
@@ -178,9 +178,13 @@ HideWindow is regarded as Iconify.
.IP "\fBScrollBarWidth\fP \fIn\fP
The variable scroll window is set \fIn\fP and defaults to 16 if
unspecified.
.IP "\fBFlushMenu\fP \fIspeed\fP \fIflashes\fP"
.IP "\fBFlashMenu\fP \fIspeed\fP \fIflashes\fP"
Determines how fast the flashes are when you choose an option from a menu,
as well as how many times it does so.
.IP "\fBFlushMenu\fP \fIspeed\fP \fIflashes\fP"
Determines how fast the flashes are when you choose an option from a menu,
as well as how many times it does so. This is deprecated and will be
removed in a future version, so please use \fBFlashMenu\fP instead.
.IP "\fBIconPath\fP \fIpath\fP"
Specify the path \fImlvwm\fP is to search in order to find it's icons.
Separate directories should be separated with a : and listed in the order
+10 -3
View File
@@ -477,12 +477,18 @@ void SetBarWidth( char *line, FILE *fp )
Scr.bar_width = bar_width;
}
void SetMenuFlash( char *line, FILE *fp )
{
if( sscanf( line, "FlashMenu%d%d", &(Scr.flash_time), &(Scr.flash_times) ) != 2 )
DrawErrMsgOnMenu( "You must set FlashMenu", " length and times" );
Scr.flash_time *= 1000;
}
void SetMenuFlush( char *line, FILE *fp )
{
if( sscanf( line, "FlushMenu%d%d", &(Scr.flush_time), &(Scr.flush_times) )
!=2 )
if( sscanf( line, "FlushMenu%d%d", &(Scr.flash_time), &(Scr.flash_times) ) != 2 )
DrawErrMsgOnMenu( "You must set FlushMenu", " length and times" );
Scr.flush_time *= 1000;
Scr.flash_time *= 1000;
}
void SetSystem8( char *line, FILE *fp )
@@ -741,6 +747,7 @@ config_func main_config[]={
{ "DoubleClickTime", SetDoubleClickTime },
{ "DisplayDeskNumber", SetDisplayDeskNum },
{ "EdgeResistance", SetEdgeResist },
{ "FlashMenu", SetMenuFlash },
{ "FlushMenu", SetMenuFlush },
{ "FollowToMouse", SetFollowToMouse },
{ "Compatible", SetCompatible },
+3 -3
View File
@@ -461,11 +461,11 @@ void ExecMenu( MenuLabel *m, int selected )
if( !(tmp_item->mode&SELECTON) || !(tmp_item->action ))
return;
for( lp=0; lp<Scr.flush_times; lp++ ){
for( lp=0; lp<Scr.flash_times; lp++ ){
DrawMenuItem( m, selected, False ); XFlush( dpy );
sleep_a_little( Scr.flush_time );
sleep_a_little( Scr.flash_time );
DrawMenuItem( m, selected, True ); XFlush( dpy );
sleep_a_little( Scr.flush_time );
sleep_a_little( Scr.flash_time );
}
DrawMenuItem( m, selected, True );
+2 -2
View File
@@ -190,8 +190,8 @@ void InitScrParams( void )
Scr.ShortCutRoot = NULL;
Scr.double_click_time = 300;
Scr.bar_width = 16;
Scr.flush_time = 100000;
Scr.flush_times = 2;
Scr.flash_time = 100000;
Scr.flash_times = 2;
Scr.zoom_wait = 10000;
Scr.IconPath = NULL;
Scr.BalloonOffStr = NULL;
+2 -2
View File
@@ -103,8 +103,8 @@ typedef struct ScreenInfo
unsigned int flags;
int double_click_time;
int bar_width;
int flush_time;
int flush_times;
int flash_time;
int flash_times;
int resist_x, resist_y;
int zoom_wait;