Opened 19 years ago

Closed 12 years ago

Last modified 12 years ago

#484 closed bug (fixed)

[app_server] menu flickering

Reported by: diver Owned by: leavengood
Priority: normal Milestone: R1
Component: Servers/app_server Version: R1/Development
Keywords: Cc: Adek336, stippi
Blocked By: Blocking:
Platform: All

Description (last modified by diver)

MenuItems flickers if they have submenu.
To reproduce it open desktop context menu and navigate to New.
You might need to do it several times to notice it.

Attachments (1)

484_menu_fixes.diff (1.0 KB ) - added by leavengood 12 years ago.
Small menu changes to remove flickering

Download all attachments as: .zip

Change History (40)

comment:1 by axeld, 19 years ago

Owner: changed from axeld to jackburton

comment:2 by jackburton, 19 years ago

Status: newassigned

comment:3 by jackburton, 19 years ago

Status: assignedclosed

comment:4 by jackburton, 19 years ago

Fixed in hrev17168

comment:5 by jackburton, 19 years ago

Resolution: fixed

comment:6 by diver, 19 years ago

Status: closedreopened

comment:7 by diver, 19 years ago

Resolution: fixed

comment:8 by diver, 19 years ago

Happens again, but this time it even worse, you can't see selection when you move your mouse fast over menulist, it didn't happen before.

comment:9 by jackburton, 18 years ago

The problem is fixed in hrev17519 (I can no longer reproduce it). Was caused by the wrong initialization of "closeTime" in BMenu::_track().

comment:10 by jackburton, 18 years ago

Resolution: fixed

comment:11 by jackburton, 18 years ago

Status: reopenedclosed

comment:12 by diver, 18 years ago

Well, for me it's look better, but still have some (rare) flickering :-( What about "you can't see selection when you move your mouse fast over menulist " thing. It still there, should i open another bug for this?

comment:13 by jackburton, 18 years ago

Actually the commit I've done should've fixed this very problem. The menu flickering was gone long ago. I can't reproduce neither of these problems anymore now. Neither on real hardware or qemu or vmware. Are you sure you tried the latest revision ? On which hardware are you running haiku ?

comment:14 by diver, 18 years ago

I tested it nativly and under vmware, and there were flickering yes, i will recheck with newes revision, though. I have a P4 1,8Ggz 786 ram and geforce 4mx.

comment:15 by diver, 18 years ago

If you run cat /dev/random in terminal and move your mouse above items in application folder in deskbar you will see icon flickering, tested with hrev17592 under vmware.

comment:16 by diver, 18 years ago

Component: GeneralUser Interface/InterfaceKit
Platform: All
Resolution: fixed
Status: closedreopened
Version: R1

Ok i found the way to reproduce it now! It seems that flickering could be seen on heavy load. Launch ProcessController and install to deskbar. Launch GLTeapot and resize it's window so it would take 100% of cpu time. Click on Options menu and move mouse above menuitems. You could even crash GLTeapot if you middleclick on teapot, but i'll open another bug for this.

Tested unser vmware with hrev18800. Hope this would help.

comment:17 by jackburton, 18 years ago

Component: User Interface/InterfaceKitUser Interface/app_server
Description: modified (diff)
Owner: changed from jackburton to axeld
Status: reopenednew

I'm reassigning to app_server, as you can see flickering on heavy load on many other places, not just menu, so I'm assuming it's not related to menus only. Feel free to reassign it to me if you think it's not the case.

comment:18 by diver, 18 years ago

Yet another way to reproduce flickering:
open /boot/beos and right click bin folder, then select several times bin menuitem.

comment:19 by diver, 17 years ago

Can't reproduce under vmware, but on real hw i can, so it seems to be app_server problem indeed.

comment:20 by diver, 16 years ago

I can reproduce it in VirtualBox.

comment:21 by stippi, 16 years ago

If I select the bin folder and move my mouse away again to deselect it, I can see an ever so slight flickering when the background is first drawn and then the menu item label with a tiny delay. If that is what you mean, I would say I can live with it. The rest of the bug report, like that not all items get selected when you move your mouse quickly up or down over the items is actually intentional.

comment:22 by diver, 16 years ago

Yeah, that's what i mean.

comment:23 by anevilyak, 16 years ago

So does something need to be fixed here or not?

in reply to:  21 comment:24 by diver, 16 years ago

Yeah, see comment:21 by stippi.

comment:25 by Adek336, 16 years ago

Cc: adek336@… added

Also note #913 with screenshots.

Also when browsing the file system with the context menu on the Desktop one may see the menu draw a split second earlier than the contents draw. Also when I click on the Desktop and all the submenus are closed I can sometimes see a menu without contents.

This is bad because it makes a bad impression on users that Haiku is slow and unresponsive.

comment:26 by diver, 15 years ago

Still here in hrev32617, should I create a separate ticket for comment:25?

comment:27 by axeld, 15 years ago

Yes please.

comment:28 by diver, 15 years ago

Generally reproducible with cpu (or app_server) intensive application like Kaleidoscope running in VirtualBox.

comment:29 by diver, 15 years ago

Version: R1/pre-alpha1R1/Development

comment:30 by diver, 14 years ago

Summary: MenuItem flickering[app_server] menu flickering

Still reproducible in VirtualBox 3.0.12 with hrev38300.

comment:31 by diver, 12 years ago

Cc: Adek336 stippi added; adek336@… removed
Description: modified (diff)

MenuBar items seem to flicker on deselection, so it could be an InterfaceKit issue after all.

comment:32 by leavengood, 12 years ago

Stephan has more or less already solved this issue, he just did it only in WebPositive:

// TODO: Small hack for fixing some invalidation problems with BMenuBar...
mainMenu->SetFlags(mainMenu->Flags() | B_FULL_UPDATE_ON_RESIZE);
mainMenu->SetViewColor(B_TRANSPARENT_COLOR);

Applying similar changes to BMenu (the transparent view color) and BMenuBar (the full update on resize flag) seems to fix the issue. I can't imagine this fix causing big problems, except maybe for really old BeOS apps which somehow depend on this misbehavior (though I'm not sure if this is exactly how BeOS worked either.)

I will attach a patch in case others want to take a look before I commit it.

by leavengood, 12 years ago

Attachment: 484_menu_fixes.diff added

Small menu changes to remove flickering

comment:33 by leavengood, 12 years ago

patch: 01

comment:34 by diver, 12 years ago

The patch fixes this bug, also menus dis(appears) a little bit faster with this patch as well.

comment:35 by diver, 12 years ago

It seems that this patch also fixes #532 and #4335.

comment:36 by leavengood, 12 years ago

Nice! Thanks for checking those diver. So this really sounds like a winner, but I'll let some other devs weigh in before I commit it.

comment:37 by leavengood, 12 years ago

Owner: changed from axeld to leavengood
Status: newin-progress

OK patch applied in hrev44458.

comment:38 by leavengood, 12 years ago

Resolution: fixed
Status: in-progressclosed

comment:39 by leavengood, 12 years ago

patch: 10
Note: See TracTickets for help on using tickets.