This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > VRML > January 2004 > Re: Blaxxun - display script in browser status line





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Re: Blaxxun - display script in browser status line
Bill Angel

2004-01-13, 7:29 am

Hi:

The code in your example appears to be correct.
The problem is that you commented out lines that write
the string to the browser status line.

This is the code that is in the file lib_SO_proto.wrl, as downloaded
from your site:

# Blaxxun version
DEF display_Message Script {
field SFString labelString IS objName
eventIn SFBool set_boolean
url [
"java script:
function set_boolean (bolValue) {

// Set popup label
// if( bolValue == true ) { Browser.setDescription(labelString); }
if( bolValue == true ) { Browser.print(labelString); }
// Syntax - for Blaxxun compatibility - remove if ... else statement
// if( bolValue == false ) { Browser.setDescription(''); }
if( bolValue == false ) { Browser.print(''); }
}"
] # end url
# Output events for browser router are implied
} # end Script


Note that the Browser.setDescription(...) lines have been commented out
in that file. If you uncomment those lines, then the Names of the objects
are written to the Browser status line when Blaxxun Contact is the plug-in.

--- Bill Angel


"PrisNo6" <fisherka@csolutions.net> wrote in message news:9865fa0b.0401130035.6d6f3ffa@posting.google.com...
quote:

> The following is a basic script to display an object name in a browser
> on touch. This works in Cortona, CosmoPlayer, but not Balxxun. What
> do I need to do make it work in Blaxxun? In Blaxxun, all that happens
> is the browser displays the word "touch" on the status line in MS IE
> 6.0.
>
> # Popup label in browser status bar
> # Blaxxun version
> DEF display_Message Script {
> field SFString labelString IS objName
> eventIn SFBool set_boolean
> url [
> "java script:
> function set_boolean (bolValue) {
>
> // Set popup label
> if( bolValue == true ) { Browser.setDescription(labelString); }
> if( bolValue == false ) { Browser.setDescription(''); }
>
> }"
> ] # end url
> # Output events for browser router are implied
> } # end Script
> # Router for popup label in browser
> ROUTE sense_Sphere_Object.isOver TO display_Message.set_boolean
> # End routers
>
> Objects and protos are in:
>
> http://members.csolutions.net/fishe...roBlax/miniver/
>
> Script is in:
>
> http://members.csolutions.net/fishe...ib_SO_proto.wrl
>
> lib_SO_proto is external and is invoked and spheres are instanced by:
>
> http://members.csolutions.net/fishe...bjectTester.wrl
>
> - Regards Kurt




PrisNo6

2004-01-13, 5:30 pm

"Bill Angel" <wtangel@shell.cais.net> wrote in message news:<bu0k46$1ji$1@ngspool-d02.news.aol.com>...
quote:

> The problem is that you commented out lines that write
> the string to the browser status line. <snip>
> if( bolValue == true ) { Browser.print(labelString); }


<snip> If you uncomment those lines, then the Names of the objects
quote:

> are written to the Browser status line when Blaxxun Contact is the plug-in.



Thanks. I am downloading the Blaxxun documentation manual, so
hopefully that will reduce the number of questions I have been posted.
Along these Blaxxun lines:

Q1. To maintain cross-browser capability, is there a method to
encapsulate Blaxxun unique syntax in a function that only Blaxxun will
read, but the other browsers will pass over? I thought I saw something
posted here that was using a "vrmlscript:" tag.

Q2. When should I be concerned about shared vs. single-user behavior
when writing for the Blaxxun multi-user environment? The "on-touch"
sensor discussed above is intended to display only on an individual
user's screen and not be a shared behavior. I am trying to port a
light-weight low-behavior version of my astronomical plotting mini-app
that might also work under Blaxxun. The "on-touch" behavior is to
allow individual users to identify objects, but would not be expressed
to multiple users.

Whatever tips the group can provide would be appreciated.

Regards - Kurt

P.S. - Point-of-information. Under Contact and MS IE 6.0, the
"on-touch" sensor action does not display in IE's status line; it
displays in the Blaxxun console - which is acceptable behavior for my
purposes.
Joerg Scheurich aka MUFTI

2004-01-14, 6:29 am

> Q1. To maintain cross-browser capability, is there a method to
quote:

> encapsulate Blaxxun unique syntax in a function that only Blaxxun will
> read, but the other browsers will pass over? I thought I saw something
> posted here that was using a "vrmlscript:" tag.



"vrmlscript:" is a "cosmo"ism that is equivalent to "java script:"

You can find it in output from cosmo-tools like some cosmoworlds versions,
but usually "vrmlscript:" is outdated.

so long
MUFTI
--
! WARNING: Debugging this process may result in loss of data.
Are you sure you wish to attach the debugger ?
Yes No
(aus einer Windows Fehlermeldung)
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews