OS4 DepotLogo by Alkaron 
(anonymous IP: 3.135.212.142,0) 
 HomeRecentStatsSearchMirrorsContactInfoDisclaimerConfigAdmin
 Menu

 Features
   Crashlogs
   Bug tracker
   Locale browser
 

 Categories

   o Audio (343)
   o Datatype (51)
   o Demo (203)
   o Development (602)
   o Document (24)
   o Driver (97)
   o Emulation (148)
   o Game (1010)
   o Graphics (500)
   o Library (118)
   o Network (233)
   o Office (66)
   o Utility (932)
   o Video (69)

Total files: 4396

Full index file
Recent index file

 Links

  Amigans.net
  OpenAmiga
  Aminet
  UtilityBase
  IntuitionBase
  AmigaBounty


Support the site


 Readme for:  Utility » Misc » daysleeper.lha

DaySleeper

Description: Shutdown/reboot at a selected time
Download: daysleeper.lha       (TIPS: Use the right click menu if your browser takes you back here all the time)
Size: 130kb
Version: 0.9r2
Date: 31 Mar 14
Author: r-tea amiga pl (Artur r-tea Ostrowski), aos4 port by kas1e
Submitter: kas1e
Email: kas1e/yandex ru
Requirements: MUI4-R3 minimum because of new Clock.mcc class (http://muidev.de)
Category: utility/misc
Replaces: utility/misc/daysleeper.lha
License: Other
Distribute: yes
Min OS Version: 4.1
FileID: 8710
 
Snapshots:
 
Comments: 6
Snapshots: 1
Videos: 0
Downloads:  (Current version)
 (Accumulated)

[Show comments] [Show snapshots] [Show videos] [Show content] [Show crashlogs] 
aos4 fixes:

 ** r2:

 -- added code so iconify show daysleeper icon on wb, and not default mui one
 -- added Mason's icon as well

 ** r1:

 --added forgoten droping of muimasteriface at exit (so expunge will works)
 --replaced all %d on %ld (beacuse taking 16bit arguments from stack suck, and
on amiga everything is pushed as 32bit value onto the stack)
 --reworked some cycle-buttons related code to make cycle buttons reacts fine
(as it was done by original author there was set and input mode for cycle
buttons, which will cause mui eat all niput events for that button before the
cucle class is able to handle them itself to open the popup menu, so we just use
old macro Cycle(entries) ). Thanks to Thore for all points about.


! AOS4 NOTE: ! "Shutdown" command is not implements currently in aos4. So or you
use "reboot" functionality only, or, if you want shutdown , then just grab
necesary shutdown binary from os4depot (for peg2 its "pegoff", for sam/x1000 its
"poff"). Just rename it to "shutdown" and place somewhere in your system pathes
(like as usuall in C:)


Once upon a time my wife's brother told me he got a nice little proggy which
shuts down his computer (with Windows) while he watches a film, he got asleep
and the film ends. I answered I don't have such a programm but I can create
similar thing.

And that was the purpose of creating this little clock / time utility.The second
(and maybe more important) reason for which I created this program was that I
love MUI as an user and as a "sunday programmer" :-) I consider MUI API as
really cool and easy to use for not very experienced programmers like me. And I
consider MUI GUI and all MUI's environment (from an user point of view) as the
best environment one's ever seen.

A long time had elapsed since my last attempts of programming, so it was a good
opportunity to start it again :-)

Now facts:

Program was compiled on MorphOS 3.3 (MUI 4.2 debug) with GCC compiler. As well
as port to AmigaOS4 done by kas1e for mui4-r3 (http://muidev.de), which have
necessary clock.mcc class.

Source, with lots of comments, included.

NOTE! This is not good exapmle of building proper MUI application. In fact this
is the worst example of it :-) I used the main MUI loop and put there all the
programm handling events. This is the easiest way for "sunday programmers" but
remember: the worst way to buid a serious MUI application, thus consider it as
an example for very beginners.

Feel free to distribute the source code, share with it, do any changes as well
as copy all or parts of it. Just play with it and see how brilliant is MUI :-)

Please, let me know if you found it useful in any way, either if you have any
suggestions or comments. Would be nice to receive a grab of Daysleeper window
with your MUI's favourite prefs :-)

For those who want to play with my lame code :-) This is the command line string
I used to compile the source:

For GCC compiler on morphos:
gcc -noixemul -o executable sourcecode

For compile on amigaos4:
gcc -D__USE_INLINE__ -o executable sourcecode  -lauto


-noixemul	  compiler uses libnix.library instead of ixemul.library.
			  It makes output code much bigger but saves system recources -
			  memory, disk operation etc.
executable	  is the name of output code
souurcecode	  is your program source code (with path if you need)


For VBCC compiler:
vc exec -+ -lauto -lmieee -o myprogram

some explanatios:

exec	   name of output code
-+		   to make use of C++ like comments
-lauto	   don't know what for but needed :-)
-lmieee	   to make use of mathematical standard ANSI C libs
-o 		   your program source code (with path if you need)


MUI's author: Stefan Stuntz. Further developing by MorphOS Team.
AmigaOS4 version of MUI: Stefan Stuntz. Futher developing by Thore and Jens.
Amiga VBCC author: Frank Wille
The clock icon comes from Aminet, from Alpyreicons1 set by Alper Sonmez.





Copyright (c) 2004-2024 by Björn Hagström All Rights Reserved
Amiga OS and its logos are registered trademarks of Hyperion Entertainment