aboutsummaryrefslogtreecommitdiff
path: root/src/MTools/Widget/MBouton.pm
diff options
context:
space:
mode:
authordidier2007-11-09 14:23:52 +0000
committerdidier2007-11-09 14:23:52 +0000
commitd587ffb205c30c978c3f44429266025728616178 (patch)
treead49732009f7b804f3dd4a3bb7fbcc0e4df16822 /src/MTools/Widget/MBouton.pm
parent9adda8c8c8bcd917f13e9ea3ca525b82bf2b03c1 (diff)
downloadmtc-d587ffb205c30c978c3f44429266025728616178.zip
mtc-d587ffb205c30c978c3f44429266025728616178.tar.gz
mtc-d587ffb205c30c978c3f44429266025728616178.tar.bz2
mtc-d587ffb205c30c978c3f44429266025728616178.tar.xz
Ajout de 2 nouvelles widgets (Merci JL Vinot):
Une pour creer un fond d'appli selon un style passe en parametre : MControlBoard Une pour creer une "belle" fleche : MArrow Pour l'instant pas d'exemples les utilisant (si ce n'est l'appli approche Acropole), peut etre ulterieurement. Un peu de robustesse pour le MBouton...
Diffstat (limited to 'src/MTools/Widget/MBouton.pm')
-rw-r--r--src/MTools/Widget/MBouton.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/MTools/Widget/MBouton.pm b/src/MTools/Widget/MBouton.pm
index f49af90..acabe65 100644
--- a/src/MTools/Widget/MBouton.pm
+++ b/src/MTools/Widget/MBouton.pm
@@ -38,7 +38,7 @@ sub new {
my $on = minstance ($options {g_on}, $self);
my $off = minstance ($options {g_off}, $self);
- my $over = defined $options {g_over} ? minstance ($options {g_over}, $self) : $on;
+ my $over = defined $options {g_over} && $options {g_over} ne ''? minstance ($options {g_over}, $self) : $on;
my $eventOn = defined $options {e_press} ? $options {e_press} : 'PRESS';
my $eventOff = defined $options {e_release} ? $options {e_release} : 'RELEASED';
my $cb = $options {call} if (defined $options {call});
@@ -55,7 +55,7 @@ sub new {
my @gover;
push (@gover, $over);
- if (defined $options {g_text})
+ if (defined $options {g_text} && $options {g_text} ne "")
{
$self -> recordProperty ('text', $options {text});
my $txt = minstance ($options {g_text}, $self);