Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 24 Oct 2014, 12:39
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
Gtkdialog: Function result to disable button
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 1 of 1 Posts_count  
Author Message

Joined: 04 Feb 2014
Posts: 8

PostPosted: Tue 04 Feb 2014, 13:28    Post_subject:  Gtkdialog: Function result to disable button  

Hi there! This looks like a place where I can get some help with gtkdialog.
I'm writing a GUI for a script of mine and having trouble with some flags.

I want to have fileselect send a variable with a filepath, have it run through a md5 checker and enable an install button if md5 checks out ok.

So, fileselect to variable, have a function grab the variable and run its magic, return either true or false.
If true enable button, if false disable button.
Can this be done? I've tried creating flags within gtkdialog as well as bash function, but nothing seems to work - either returning wrong value or fileselect crashes after two failed entries.
Where can I find more advanced examples, other than those in the docs and wiki?

Back to top
View user's profile Send_private_message 

Joined: 05 Sep 2011
Posts: 2420
Location: Germany

PostPosted: Tue 04 Feb 2014, 15:04    Post_subject:  

I don't know how familiar you are with bash scripting, but to examine pmenu-3.0.0.pet could be useful, of course.

It uses functions to enable/disable and to refresh its GUI buttons.

I have have used parts from this for some of my own scripts - really useful code to find in there!

Good luck with the your scripting-project!

LazY Puppy
Back to top
View user's profile Send_private_message 
Display_posts:   Sort by:   
Page 1 of 1 Posts_count  
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » Off-Topic Area » Programming
Jump to:  

You cannot attach files in this forum
You can download files in this forum

Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0391s ][ Queries: 12 (0.0050s) ][ GZIP on ]