How to make NSComboBox work in fullscreen mode

  • Hi,

    Does anyone know how to make NSComboBox work in fullscreen mode ? In my
    application, when start fullscreen mode, I set the window level to
    CGShieldingWindowLevel().  When click on a comboBox on the window, I can't
    see anything.  And I got this message:PSsetwindowlevel, error setting window
    level (1001). The datasoure list of the comboBox seems hidden by the window.
    I guess the problem is, the datasource list of comboBox is at
    NSPopUpMenuWindowLevel<http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Cla
    sses/NSWindow_Class/Reference/Reference.html#//apple_ref/doc/c_ref/NSPopUpM
    enuWindowLevel
    >,
    so it's  hidden by the CGShieldingWindowLevel(). My question is, how
    to
    make it work ?

    Any suggestion will be appreciated.

    Thanks,

    John
  • On Oct 17, 2007, at 9:15 PM, john chen wrote:

    > Does anyone know how to make NSComboBox work in fullscreen mode ?
    > In my
    > application, when start fullscreen mode, I set the window level to
    > CGShieldingWindowLevel().  When click on a comboBox on the window,
    > I can't
    > see anything.  And I got this message:PSsetwindowlevel, error
    > setting window
    > level (1001). The datasoure list of the comboBox seems hidden by
    > the window.
    > I guess the problem is, the datasource list of comboBox is at
    > NSPopUpMenuWindowLevel<http://developer.apple.com/documentation/
    > Cocoa/Reference/ApplicationKit/Classes/NSWindow_Class/Reference/
    > Reference.html#//apple_ref/doc/c_ref/NSPopUpMenuWindowLevel>,
    > so it's  hidden by the CGShieldingWindowLevel(). My question is, how
    > to
    > make it work ?

    You cannot mix AppKit with captured displays (search archives for why).

    ___________________________________________________________
    Ricky A. Sharp        mailto:<rsharp...>
    Instant Interactive(tm)  http://www.instantinteractive.com
  • Thanks Ricky for pointing this out. So there is a bug in the sample code:

    http://developer.apple.com/documentation/Cocoa/Conceptual/CocoaDrawingGuide
    /AdvancedDrawing/chapter_9_section_4.html

    ?

    Seems this is a problem discussed a lot in this list, but I have not
    figured out a good solution for AppKit in fullscreen.

    Thanks,

    John

    On 10/17/07, Ricky Sharp <rsharp...> wrote:
    >
    > On Oct 17, 2007, at 9:15 PM, john chen wrote:
    >
    >> Does anyone know how to make NSComboBox work in fullscreen mode ?
    >> In my
    >> application, when start fullscreen mode, I set the window level to
    >> CGShieldingWindowLevel().  When click on a comboBox on the window,
    >> I can't
    >> see anything.  And I got this message:PSsetwindowlevel, error
    >> setting window
    >> level (1001). The datasoure list of the comboBox seems hidden by
    >> the window.
    >> I guess the problem is, the datasource list of comboBox is at
    >> NSPopUpMenuWindowLevel<http://developer.apple.com/documentation/
    > > Cocoa/Reference/ApplicationKit/Classes/NSWindow_Class/Reference/
    >> Reference.html#//apple_ref/doc/c_ref/NSPopUpMenuWindowLevel>,
    >> so it's  hidden by the CGShieldingWindowLevel(). My question is, how
    >> to
    >> make it work ?
    >
    > You cannot mix AppKit with captured displays (search archives for why).
    >
    > ___________________________________________________________
    > Ricky A. Sharp        mailto:<rsharp...>
    > Instant Interactive(tm)  http://www.instantinteractive.com
    >
    >
  • I got it work without capturing displays. I changed it to use
    NSMainMenuWindowLevel + 1 and  exclude the fullscreen window from expose.

    Thanks,

    John

    On 10/18/07, john chen <johnchen202...> wrote:
    >
    > Thanks Ricky for pointing this out. So there is a bug in the sample code:
    >
    >
    > http://developer.apple.com/documentation/Cocoa/Conceptual/CocoaDrawingGuide
    /AdvancedDrawing/chapter_9_section_4.html

    > ?
    >
    > Seems this is a problem discussed a lot in this list, but I have not
    > figured out a good solution for AppKit in fullscreen.
    >
    > Thanks,
    >
    > John
    >
    >
    > On 10/17/07, Ricky Sharp <rsharp...> wrote:
    >>
    >> On Oct 17, 2007, at 9:15 PM, john chen wrote:
    >>
    >>> Does anyone know how to make NSComboBox work in fullscreen mode ?
    >>> In my
    >>> application, when start fullscreen mode, I set the window level to
    >>> CGShieldingWindowLevel().  When click on a comboBox on the window,
    >>> I can't
    >>> see anything.  And I got this message:PSsetwindowlevel, error
    >>> setting window
    >>> level (1001). The datasoure list of the comboBox seems hidden by
    >>> the window.
    >>> I guess the problem is, the datasource list of comboBox is at
    >>> NSPopUpMenuWindowLevel<http://developer.apple.com/documentation/
    > > > Cocoa/Reference/ApplicationKit/Classes/NSWindow_Class/Reference/
    >>> Reference.html#//apple_ref/doc/c_ref/NSPopUpMenuWindowLevel>,
    >>> so it's  hidden by the CGShieldingWindowLevel(). My question is, how
    >>> to
    >>> make it work ?
    >>
    >> You cannot mix AppKit with captured displays (search archives for why).
    >>
    >> ___________________________________________________________
    >> Ricky A. Sharp        mailto:<rsharp...>
    >> Instant Interactive(tm)  http://www.instantinteractive.com
    >>
    >>
    >
previous month october 2007 next month
MTWTFSS
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        
Go to today