Exemple #1
0
def plugin_execute(so_file):

    import osso
    plugin = osso.Plugin(_osso_ctx)
    plugin.plugin_execute(so_file, True)
Exemple #2
0
 def show_fm_transmitter(self, ws):
     import osso
     ctx = osso.Context('Panucci', '1.3.3.7', False)
     plugin = osso.Plugin(ctx)
     plugin.plugin_execute('libcpfmtx.so', True)
Exemple #3
0
    print "saving..."
    plug.plugin_save_state(plugin)

c = osso.Context("test_client", "0.0.0", False)
as = osso.Autosave(c)
applic = osso.Application(c)
rpc = osso.Rpc(c)
print "as.get_name() ->", as.get_name()
print "as.get_version() ->", as.get_version()
print "rpc.get_rpc_timeout() ->", rpc.get_rpc_timeout()
print "rpc.set_rpc_timeout(15) ->", rpc.set_rpc_timeout(15)
print "rpc.get_rpc_timeout() ->", rpc.get_rpc_timeout()
timenot = osso.TimeNotification(c)
timenot.set_time_notification_callback(handler_test_time_notification, "Notification Callback!")
timenot.set_time(time.localtime())
plug = osso.Plugin(c)
ss = osso.StateSaving(c)

local = osso.Locale(c)

# Interface
app = hildon.App()
view = hildon.AppView("Client")
app.set_title("Test")
app.set_appview(view)
app.connect("destroy", gtk.main_quit)

vbox = gtk.VBox()

label = gtk.Label("Tests")
vbox.add(label)
Exemple #4
0
 def test_plugin_save_state(self):
     plugin = osso.Plugin(self.ctx)
     # XXX: unlike osso_cp_plugin_execute(), osso_cp_plugin_save_state()
     # requires the full path! Looks like a libosso bug.
     plugin.plugin_save_state(
         "/usr/lib/hildon-control-panel/libunittestplugin.so")
Exemple #5
0
 def test_plugin_execute(self):
     import gtk
     plugin = osso.Plugin(self.ctx)
     plugin.plugin_execute("libunittestplugin.so", True)
     plugin.plugin_execute("libunittestplugin.so", True, gtk.Window())
Exemple #6
0
 def test_constructor(self):
     app = osso.Plugin(self.ctx)
     self.assertTrue(isinstance(app, osso.Plugin))
     self.assertRaises(TypeError, osso.Plugin, None)
def main():
    osso_c = osso.Context("test_plugin_app", "0.0.1", False)

    plugin = osso.Plugin(osso_c)

    plugin.plugin_execute("libtestplugin.so", True)