mIRC Homepage
Posted By: Riamus2 Dialog Refreshing? - 13/04/05 03:11 PM
I'm working on a graphical dialog and am running into issues regarding it refreshing. It appears that mIRC refreshes the entire dialog anytime a single object is changed. As I am using multiple icons, this creates a "flicker" of everything in the dialog. Since I only want to change one icon, I don't want the entire dialog refreshing.

As a further explanation if you're wondering... the dialog has perhaps 30-40 icons in it along with other objects (text, edit boxes, etc). Because of the number of icons which are refreshed anytime something changes, you notice the flicker. If there were only a couple icons, you wouldn't notice it.

Is it possible to only refresh a single object without affecting the rest of the dialog? If not, I think I'll add this to the suggestions forum.
Posted By: clutz1572 Re: Dialog Refreshing? - 13/04/05 05:54 PM
this post looks like one of mine....
(only kidding)

not sure what you mean tho... flickering???

can you try to be a lil more specific, or perhaps show us the code so we can see what exactly going on.?
Posted By: Riamus2 Re: Dialog Refreshing? - 13/04/05 07:31 PM
The code is quite large to try displaying, though I could if you wanted.

By flickering, I mean that you see all the icons reload when a change is made to one of them. They disappear and appear one time. I'm not sure how else to explain that. It only started happening after I had many icons there. It seems as though there is a limit to how many can refresh at once without being seen refreshing. But I only need one to refresh at any given time.

If someone wants to look, when I get home I can paste in the dialog creation section and then one of the codes used to update the dialog so you can test it yourself. Just let me know if you want me to do that. Of course, you wouldn't have the images used.
Posted By: clutz1572 Re: Dialog Refreshing? - 14/04/05 02:38 PM
yes, why don't you show us some of the code please.

off hand, if i understand right. depending on how many icons the script has to load, if it's many as you say then it's possible that it's getting bogged down because the script has to load and re-load each image. normaly that shouldn't be a issue (i don't think) but if you have multitudes of images to load, then it's possible thats what's going on. i could be wrong on this but, it is possible.
Posted By: Riamus2 Re: Dialog Refreshing? - 14/04/05 04:13 PM
Yes, that is the issue. I have to remember when I am at home to paste it in. I don't have the script at work to paste from. I'll try to do that tonight.

I just don't think there is a need to reload every image if you are only changing one of them. That's why I was wondering if there is a way to avoid that.
Posted By: CtrlAltDel Re: Dialog Refreshing? - 14/04/05 04:17 PM
Quote:

The code is quite large to try displaying, though I could if you wanted.


You could always paste it at nomorepasting or nopaste and just post a link here. grin
Posted By: Riamus2 Re: Dialog Refreshing? - 14/04/05 09:45 PM
Here we go...

http://www.nomorepasting.com/paste.php?pasteID=37486
Yes, yes... there are a LOT of "icons" in this dialog and yes, that is the problem. *However*, there's no real reason all should have to refresh if only one item is refreshing.

Here are two commands which would be run that cause the refresh of everything even though only 2 icons are actually changed:

did -g GameBoard %Old.Location.ID Monopoly\PlayerNullIcon.jpg

did -g GameBoard %Location.ID Monopoly\Player1Piece1.jpg
Posted By: clutz1572 Re: Dialog Refreshing? - 15/04/05 04:14 AM
okay, i see what you mean about the icons...

what you've posted don't help much, could you posibly post a sample of the code that controls the icon switch? that would be to the point..
Posted By: Riamus2 Re: Dialog Refreshing? - 15/04/05 01:45 PM
That's what the /did -g lines above are. They change the icon images. Using them causes a complete refresh of all images rather than only affecting those two.
Posted By: clutz1572 Re: Dialog Refreshing? - 15/04/05 06:14 PM
i agree with what your saying but, apparently there's a problem somewhere in the rest of the code, somthing simple thats being overlooked most likely. (happens to me all the time).. thats why i've asked you if you could post some of the code (other than the dialog i mean smirk ).. i don't think anyone will be able to assist you without something more to go by..

and please don't get me wrong here, i'm just trying to help.. grin
Posted By: Riamus2 Re: Dialog Refreshing? - 15/04/05 06:18 PM
Ok, I'll see about posting more of the code to help out. Maybe tonight... otherwise, not until Sunday night. I've not worked with it for a long time, so I am not sure what all is there right now. I also know that it could be improved since I've learned a lot since doing the script. But, oh well. smile
Posted By: Collective Re: Dialog Refreshing? - 19/04/05 08:48 PM
I believe experienced this problem on a script a long time ago...if memory serves the method I used to fix it was to move the dialog off the screen (using dialog -s), changing the icons and moving it back onto the screen.
Posted By: Riamus2 Re: Dialog Refreshing? - 19/04/05 08:55 PM
Won't that result in the same thing... it visually changing everything? I mean, if it is moved off screen if even for a second, it would be just like refreshing all the images... there would be a "blink"/"flicker"/whatever.
Posted By: Collective Re: Dialog Refreshing? - 19/04/05 09:01 PM
My problem was more with the amount of time it took to change the icons as I was changing more than one at a time. When the dialog wasn't on the screen they loaded many times faster (for whatever reason). On testing it does create a flicker though, never mind that idea then.
Posted By: Riamus2 Re: Dialog Refreshing? - 20/04/05 02:16 PM
I see, thanks for the suggestion. I may have to see if there is a way to reduce the number of "icons" and make it still work for what I need. I still have to complete the coding of the game anyhow. This was just a matter of trying to make it look better.
© mIRC Discussion Forums