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 19 Dec 2014, 08:16
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
Problem killing extra processes when clicking on TableBox.
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [1 Post]  
Author Message
sunburnt


Joined: 08 Jun 2005
Posts: 5043
Location: Arizona, U.S.A.

PostPosted: Sat 08 May 2010, 05:14    Post subject:  Problem killing extra processes when clicking on TableBox.  

I have been chasing this one around for awhile. The click event happens on mouse up.
But you get multiple events triggering multiple processes with no easy way to control it.
It would be nice to nip this at the root just after the TableBox is clicked... Like this:
Code:
#!/bin/sh
killPSs() { sleep 2
ps |grep $0 |egrep -v '(grep|geany|getPS)' |awk '{print $1}'
}
export -f killPSs
export DM="
<window title=\"DM\" controls=\"false\"><vbox>
  <table><variable>DRIVES</variable><label>Drives|M|B</label>
  <item>1</item><item>2</item><item>3</item>
  <action signal=\"button-release-event\">killPSs</action></table>
</vbox></window>" ; gtkdialog3 -p DM --class DM_MAIN -G 116x99+99+99 &

The code only shows the processes, I can`t find code to reliably kill: all but the last prosess.
Infact you get output when the GUI first starts! From the first TableBox item being default selected I suspect.
You`ll see a list of process IDs each time you click, and different behavior if the item is preselected or not.
So as it selects and on the next click un-selects, you get more or less processes, one or two would be normal.
<table hover-selection=\"true\"> might solve it but only the TreeBox accepts the tag.
Trying to control a simple click...
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [1 Post]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Off-Topic Area » Programming
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0398s ][ Queries: 11 (0.0056s) ][ GZIP on ]