Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
100 user(s) are online (93 user(s) are browsing Forums)

Members: 2
Guests: 98

samo79, Paul, more...

Support us!

Headlines

 
  Register To Post  

I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
I have a question how do I add Iconify Icon in top border of a window? I know it has be a Reaction image button, to get align flags to work.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Amigans Defender
Amigans Defender


See User information
@LiveForIt

In a ReAction window you simply pass WINDOW_IconifyGadget, TRUE in the object definition.

The Rear Window blog

AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@trixie

it's a normal window.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@LiveForIt


fixed this is solved.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
Solved for you but what about the next person that needs to know?

Some excerpts from the AWeb code showing how to get the right image and create a title bar gadget from the buttongclass.

'win' is just a AWeb struct holding various window related data.

if(!(win->iconify_img=(struct Image *)NewObject(NULL,"sysiclass",
      
SYSIA_DrawInfo,drinfo,
      
SYSIA_Which,ICONIFYIMAGE,
      
TAG_END))) return FALSE;      

....
....
....
  if ( 
NULL != win->iconify_img )
  {
       
win->iconify_gad NewObject(NULL,"buttongclass",
         
GA_RelRight,TRUE,
         
GA_TitlebarTRUE,                               
         
GA_Imagewin->iconify_img,
         
GA_RelVerifyTRUE,
         
GA_IDGID_ICONIFY,
         
ICA_TARGETICTARGET_IDCMP,
       
TAG_END );
       if ( 
NULL != win->iconify_gad )
         
AddGadget (win->windowwin->iconify_gad0);
 }


In you window event loop do like so...

case IDCMP_GADGETUP:
               if ( 
GID_ICONIFY == ((struct Gadget *)msg->IAddress)->GadgetID )
               
Iconify (TRUE);
               break;


Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@LiveForIt

What do you need this for?
Quote:

I have a question how do I add Iconify Icon in top border of a window? I know it has be a Reaction image button, to get align flags to work.

X5000
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@Antique

Well spying on me again are we? Ok I always wonted to know how to put icons in border like that, I have not really needed it before now.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Amigans Defender
Amigans Defender


See User information
@LiveForIt

On a side note: don't be afraid to ask programming-related questions at OS4coding.net. Only then can we build a useful resource & learning centre like the dead good UtilityBase (which I still miss very much!). Of course you'll get your answer in a forum like this one, but for other people who may later be struggling with a similar problem, things will be easier to find in a dedicated place.

The Rear Window blog

AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@trixie

I found the how to on OS4coding.net, I already have too many user accounts. It be nice if some on added some pages to Amiga wiki pages about this, I think.


(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@broadblues

The code I found was a bit RAW, that's way I did not post anything, about it here.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Just can't stay away
Just can't stay away


See User information
@broadblues

Yep, using same code in MIXER

...
#define GID_ICONIFY 401
#include <intuition/sysiclass.h>
// iconify gadget
struct DrawInfo *DRI;
struct Image *IcoImg;
struct Gadget *IcoGad;
...
 
DRI IIntuition->GetScreenDrawInfo(MainScreen);
 
IcoImg = (struct Image *)IIntuition->NewObject(NULL"sysiclass"
                                       
SYSIA_DrawInfo,DRISYSIA_Which,ICONIFYIMAGE
                                      
TAG_END);
 
IcoGad = (struct Gadget *)IIntuition->NewObject(NULL"buttongclass"
                                        
GA_ID,GID_ICONIFYGA_RelVerify,TRUEGA_Image,IcoImg
                                        
GA_TopBorder,TRUEGA_RelRight,0GA_Titlebar,TRUE
                                       
TAG_END);
 
IIntuition->AddGadget(MixWindowIcoGad, -1);
...

Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Just can't stay away
Just can't stay away


See User information
Thanks, this thread was useful. Is Aweb / Mixer code available in some public version control? It would be nice to see also gadget disposal examples.

Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information
@Capehil
Quote:

Thanks, this thread was useful. Is Aweb / Mixer code available in some public version control? It would be nice to see also gadget disposal examples.


Mixer source included in archive itself: http://os4depot.net/share/audio/misc/mixer.lha

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: I have a question how do I add Iconify Icon in top border of a window?
Home away from home
Home away from home


See User information

Go to top

  Register To Post

 




Currently Active Users Viewing This Thread: 2 ( 0 members and 2 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project