Re: [Newbies] Screensaver detection
On Feb 13, 2008 10:53 AM, Uwe Loew [EMAIL PROTECTED] wrote: Hello squeak professionals, in our process monitoring software we use a background process to update the displayed values. breakFlag := false. delay := Delay forMilliseconds: 10. Processor fork: [ [ breakFlag ] whileFalse: [ backgroundProcess := true. Process is now active delay wait. .calling the GUI update methods displaying the measured values from the process delay wait. ]. backgroundProcess := false. Process is going to terminate ] at: Processor userPriority - 5 Processor is an instance of ProcessScheduler. Something in our GUI update software wastes memory and over some days crashes the system. So the user has to stop the background display process when leaving the system and to restart it when coming back. We now want to automate this switching on and off of the GUI updates by checking the screensaver status of windows. Our wish is to check in each update cycle, whether the windows-screensaver is on, and depending on this status, to update the GUI display or not. Can anybody of you give us a hint, how to check, whether windows has switched of the desktop-display and displaying the screensaver, or is still displaying the desktop containing the squeak window? Which OS? Windows, Mac, Linux, other? One option is to find and fix your memory leak. I haven't tried this before in Squeak (my applications crash much earlier than that :-P ), but I'd probably start by doing something like: Smalltalk collect: [ :each | (each isMemberOf: Class) ifTrue: [ each name, ': ', each allInstances size, ' instances' ]. (there might be a #numInstances method on Behavior; I don't have an image handy right now) Inspecting the result after running your program for some time might give some clues as to what is using up your memory. You could write a custom screensaver in C, or maybe even in Squeak if you're keen, and then that screensaver could somehow send a signal to your application - maybe using TCP/IP, or maybe sending a signal to Squeak (can Squeak capture POSIX signals?), or some other mechanism. Gulik. -- http://people.squeakfoundation.org/person/mikevdg http://gulik.pbwiki.com/ ___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners
Re: [Newbies] Simple Precedence question
Randal L. Schwartz wrote: ... Now for the cascade... we do another message send to whatever the most recent *receiver* was ... Thanks. That makes perfect sense. -- Jeffrey Straszheim http://straszheim.50megs.com ___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners
[Newbies] Simple Precedence question
So, I'm learning Smalltalk for the first time, and I have a very simple question regarding the precedence of the cascade operator. So, in this expression: self something: anObject selector ; anotherSelector. Is the target of *anotherSelector* anObject, or self? In other words, does it parse like this self something: (anObject selector ; anotherSelector). or self something: (anObject selector) ; anotherSelector. Also, what is the general principle that determines this. Thanks in advance. -- Jeffrey Straszheim http://straszheim.50megs.com ___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners
[Newbies] Screensaver detection
Hello squeak professionals, in our process monitoring software we use a background process to update the displayed values. breakFlag := false. delay := Delay forMilliseconds: 10. Processor fork: [ [ breakFlag ] whileFalse: [ backgroundProcess := true. Process is now active delay wait. .calling the GUI update methods displaying the measured values from the process delay wait. ]. backgroundProcess := false. Process is going to terminate ] at: Processor userPriority - 5 Processor is an instance of ProcessScheduler. Something in our GUI update software wastes memory and over some days crashes the system. So the user has to stop the background display process when leaving the system and to restart it when coming back. We now want to automate this switching on and off of the GUI updates by checking the screensaver status of windows. Our wish is to check in each update cycle, whether the windows-screensaver is on, and depending on this status, to update the GUI display or not. Can anybody of you give us a hint, how to check, whether windows has switched of the desktop-display and displaying the screensaver, or is still displaying the desktop containing the squeak window? Thank you very much. Best regards Uwe___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners
Re: [Newbies] Squeak for the Asus eee
Hi, Have you tried the translation of: http://el-directorio.org/Squeak/Instalacion#head-9f31bb7843147795b89ecbe76e961b906a672c12 from Spanish to English (may be using some online free translation services)? there is detailed documentation and friendly enough. If you have tried to follow this translation and still don't understand, please don't hesitate to ask again. Cheers, Offray alanomaly wrote: Could you make these instructions more beginner friendly please? I don't know what executing an image means - all I know is, opening the .sh file brings up a couple of blocks of coding in a text file. Looks like this:- #!/bin/sh APP=`dirname $0` EXE=$APP/Contents/Linux686 RES=$APP/Contents/Resources exec $EXE/squeak -plugins $EXE \ -encoding latin1 \ -vm-display-X11 -swapbtn \ $RES/seaside.image Is this the image? If so what do I do with it? Not a linux expert, just someone used to Windows who niavely believed the eee would be easy... Thanks! mike.vidal wrote: Does anyone know where there is a version of Squeak that will install on the Asus eee? I tried the debian and generic linux version and they dont install/work. The debian version wong apt-install. It complains about missing binfmt-support dependency. The linux version segfaults. ___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners ___ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners