RE: lingo-l MUI OSX

2004-10-11 Thread Rob Wingate
Dean,

 Any help would be appreciated.

There are a few things of note in the MUI code you posted:

 on dotMUI me

The fact that 'dotMUI' from your MUI BIRTH  CALLBACK ROUTINES has 'me'
after the handler name indicates that this code may reside in a behavior or
parent script. To work properly, MUI callback handlers need to reside in
movie scripts.

 gMuiLoginProps.modal= FALSE

I can't really think of a situation where a 'login' dialog box should be
non-modal. You might avoid the problem altogether if gMuiLoginProps.modal =
TRUE, using Run() instead of WindowOperation().

 case( widgeName ) of
   Close MUI: WindowOperation (gMuiLoginObject, #hide)
 end case

If you're having trouble getting the button or closebox to cause the dialog
to vanish, replace the 2nd line with this:

gMuiLoginObject.WindowOperation(#hide)
gMuiLoginObject.Stop(FALSE)
gMuiLoginObject = VOID


You'd also want to trap the callback handler's #itemClicked event to store
whatever username the user enters.

Finally, and most importantly, for a login dialog, I'd suggest you use
BudAPI's baLogin() instead of MUI:

strUserName = baPrompt(Login to the VOTH Music Vault, User Name, EMPTY,
0,-2,-2)

It accomplishes everything you're doing with MUI in a single line, plus its
4th 'flags' parameter makes it much more configurable.

HTH,
Rob

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email [EMAIL 
PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping 
with programming Lingo.  Thanks!]


RE: lingo-l MUI OSX

2004-10-08 Thread Dean Eyford
Well here are the scripts I'm having trouble with. I have included my
startMovie script that loads my custom menu. I've also included the contents
of my Field member that is my custom menu.

On my machine in projector mode the button and the close box do not work.
I'm probably missing something obvious having spent so much time trying to
port to OSX I'm getting quite frustrated. Any help would be appreciated.

Dean

CUSTOM MENU FIELD MEMBER
--
menu: menuName
Hello | alert(Hello World)


START MOVIE SCRIPT
--
on startMovie
  dotMUI()
  installMenu myMenu
end



MUI BIRTH  CALLBACK ROUTINES.
--
global gMasterObject, gMuiLoginObject, gMuiLoginProps, gMuiLoginItems,
gWidgetTitleList

on dotMUI me
  put( Here I am... OSX MUI tester)

  gMuiLoginObject=new(xtra MUI)
  gMuiLoginProps =gMuiLoginObject.getWindowPropList()
  gMuiLoginProps.modal= FALSE
  gMuiLoginProps.closeBox= TRUE
  gMuiLoginProps.mode= #data --units that vary in size depending on the
system font, about 1.5 times larger than pixels depending on the font and
point size
  gMuiLoginProps.name=Login to the VOTH Music Vault
  gMuiLoginProps.callback=enterPasswordMuiActions_MAC()

  --INIT LIST TO CONTAIN ALL MUI ITEMS OR WIDGETS
  gMuiLoginItems=[]

  widgetPropList = gMuiLoginObject.GetItemPropList()
  widgetPropList.type = #windowBegin
  widgetPropList.title = windowBegin
  gMuiLoginItems.append( widgetPropList.duplicate() )

  --Label for User Name
  widgetPropList=gMuiLoginObject.GetItemPropList()
  widgetPropList.value  = User Name   --empty spaces
are added to value to increase the width
  widgetPropList.type = #Label
  widgetPropList.title = User Name Label
  gMuiLoginItems.append( widgetPropList.duplicate() )

  --Field for UserName Name
  widgetPropList = gMuiLoginObject.getItemPropList()
  widgetPropList.type = #editText
  widgetPropList.value = EMPTY
  widgetPropList.title = User Name Field
  gMuiLoginItems.append( widgetPropList.duplicate() )

  --OK BUTTON
  widgetPropList = gMuiLoginObject.getItemPropList()
  widgetPropList.type = #pushButton
  widgetPropList.value = EMPTY
  widgetPropList.title = Close MUI
  gMuiLoginItems.append( widgetPropList.duplicate() )

  widgetPropList=gMuiLoginObject.GetItemPropList()
  widgetPropList.type=#windowEnd
  widgetPropList.title= windowEnd
  gMuiLoginItems.append( widgetPropList.duplicate() )

  Initialize (gMuiLoginObject,[#windowPropList:gMuiLoginProps,
#WindowItemList: gMuiLoginItems])
  WindowOperation (gMuiLoginObject, #show) --open a non-modal window
(remember to set gMuiLoginProps MODAL to False)
  -- Run (gMuiLoginObject) --creates a modal window
  RETURN
end dotMUI me

--
on enterPasswordMuiActions_MAC event, widgeNum, widgeProps
  --
  put This is the event event
  if voidP(widgeNum) then
--put Window event detected:  event
  else
set widgeType=the type of widgeProps
--put widgeType = widgeType
set widgeName=the title of widgeProps
set widgeValue=the value of widgeProps
--put Widget  widgeName  generated a:  event
Event!
  end if  --  voidP(widgeNum)
  --
  case (event) of
#windowOpening:
#itemEnteringFocus:
#itemLosingFocus:
#itemChanged: --use this to trigger events when the user changes a
checkBox
#itemClicked: -- Use at least 3 characters!
  case( widgeName ) of
  Close MUI: WindowOperation (gMuiLoginObject, #hide)
  end case

  end case --(event) of
end enterPasswordMuiActions_MAC

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Rob Wingate
Sent: Thursday, October 07, 2004 12:31 PM
To: [EMAIL PROTECTED]
Subject: Re: lingo-l MUI  OSX


 Can anyone confirm getting an MUI with a callback()
 handler working in projector mode on a Mac running
 OSX?

Daily.

 The MUI will appear but editText  buttons will not
 respond. I can only get Modal MUIs to work in
 authouring mode,

Post your dialog-creation and callback code, and I'll see if I can help.

Rob

[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email
[EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is
for learning and helping with programming Lingo.  Thanks!]

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email [EMAIL 
PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping 
with programming Lingo.  Thanks!]


Re: lingo-l MUI OSX

2004-10-07 Thread Rob Wingate
 Can anyone confirm getting an MUI with a callback()
 handler working in projector mode on a Mac running
 OSX?

Daily.

 The MUI will appear but editText  buttons will not
 respond. I can only get Modal MUIs to work in
 authouring mode,

Post your dialog-creation and callback code, and I'll see if I can help.

Rob

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email [EMAIL 
PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping 
with programming Lingo.  Thanks!]