Skip to content
This repository has been archived by the owner on Dec 20, 2020. It is now read-only.

Commit

Permalink
Use a white background for the "Invalid" songs, too.
Browse files Browse the repository at this point in the history
Apply the red color style to invalid songs in the holding tank, too.
  • Loading branch information
minter committed Sep 17, 2004
1 parent 82dd554 commit f0a5e18
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ChangeLog
Expand Up @@ -2,6 +2,8 @@ Fri Sep 17 2004 H. Wade Minter (minter@lunenburg.org)
* Get the move_tank function working with the HList. Thanks to
Kyle at sickduck.org for the help.
* Move the CWX-specific functions to their own branch.
* Use a white background for the "Invalid" songs, too.
* Apply the red color style to invalid songs in the holding tank, too.

Mon Sep 13 2004 H. Wade Minter (minter@lunenburg.org)
* Make nice white backgrounds by default for listboxes and entry
Expand Down
24 changes: 24 additions & 0 deletions mrvoice.pl
Expand Up @@ -2614,6 +2614,18 @@ sub move_tank
$direction, $neighbor
);

my $info = get_info_from_id($target);
if ( !-e catfile( $config{'filepath'}, $info->{filename} ) )
{
my $style = $tankbox->ItemStyle(
'text',
-foreground => 'red',
-background => 'white',
-selectforeground => 'red'
);
$h->entryconfigure( $target, -style => $style );
}

#...and assumedly we want the newly re-inserted item to be selected...
$h->anchorSet($target);

Expand Down Expand Up @@ -3076,6 +3088,7 @@ sub do_search
my $style = $mainbox->ItemStyle(
'text',
-foreground => 'red',
-background => 'white',
-selectforeground => 'red'
);
$mainbox->entryconfigure( $row_hashref->{id}, -style => $style );
Expand Down Expand Up @@ -3403,6 +3416,17 @@ sub Tank_Drop
my $text = $parent->itemCget( $index, 0, '-text' );
my $id = $parent->info( 'data', $index );
$tankbox->add( $id, -data => $id, -text => $text );
my $info = get_info_from_id($id);
if ( !-e catfile( $config{'filepath'}, $info->{filename} ) )
{
my $style = $tankbox->ItemStyle(
'text',
-foreground => 'red',
-background => 'white',
-selectforeground => 'red'
);
$tankbox->entryconfigure( $id, -style => $style );
}
}
if ( $#indices > 1 )
{
Expand Down

0 comments on commit f0a5e18

Please sign in to comment.