diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | 90825e2392b2d70e43c7a25b8a3752299a933894 (patch) | |
tree | e33aa27f02b74604afbfd0ea4f1cfca8833d882a /kjsembed/tests/plugin.js | |
download | tdebindings-90825e2392b2d70e43c7a25b8a3752299a933894.tar.gz tdebindings-90825e2392b2d70e43c7a25b8a3752299a933894.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebindings@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kjsembed/tests/plugin.js')
-rw-r--r-- | kjsembed/tests/plugin.js | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/kjsembed/tests/plugin.js b/kjsembed/tests/plugin.js new file mode 100644 index 00000000..04d91a4f --- /dev/null +++ b/kjsembed/tests/plugin.js @@ -0,0 +1,40 @@ + +var plugins = Factory.listBindingPlugins(); +println("Currently Usable Plugins:"); +for ( var idx = 0; idx < plugins.length; ++idx) + println(plugins[idx]); + +try { +var invalid1 = new NotReallyThere(this); +} +catch(ex) { +println('Exception: '+ex); +} + +var foo1 = new MyCustomObject(this); +var foo2 = new MyCustomObject(this); + +foo1.setThing("Test"); + +println( foo1.On ); +println( foo1.Off ); + +foo2.setMode(foo2.On); +foo2.setThing(foo2.thing()); + +if( foo2.mode() == foo1.On ) +{ + var foo3 = foo2; + println("Foo3 thing " + foo3.thing()); + +} + +var foo4 = new MyCustomQObject(this); + +foo4.mode = foo4.On; +foo4.thing = "Test"; + +if( foo4.mode ) +{ + println( foo4.thing ); +} |