Home | Trees | Indices | Help |
|
---|
|
object --+ | util.IEventListener --+ | terminal.paintable.IPaintable --+ | object --+ | | | terminal.variable_owner.IVariableOwner --+ | object --+ | | | terminal.sizeable.ISizeable --+ | component.IComponent --+ | object --+ | | | event.method_event_source.IMethodEventSource --+ | abstract_component.AbstractComponent --+ | UriFragmentUtility
Experimental web browser dependent component for URI fragment (part after hash mark "#") reading and writing.
Component can be used to workaround common ajax web applications pitfalls: bookmarking a program state and back button.
|
|||
CLIENT_WIDGET = None hash(x) |
|||
Inherited from Inherited from |
|
|||
Inherited from |
|
Registers a new (generic) component event listener for the component: class Listening(CustomComponent, IListener): # Stored for determining the source of an event ok = None status = None # For displaying info about the event def __init__(self): layout = VerticalLayout() # Some miscellaneous component name = TextField("Say it all here") name.addListener(self) name.setImmediate(true) layout.addComponent(name) # Handle button clicks as generic events instead # of Button.ClickEvent events ok = new Button("OK") ok.addListener(self) layout.addComponent(ok) # For displaying information about an event status = new Label("") layout.addComponent(status) setCompositionRoot(layout) def componentEvent(event): # Act according to the source of the event if (event.getSource() == ok): getWindow().showNotification("Click!") status.setValue("Event from " + event.getSource().__class__.__name__ + ": " + event.__class__.__name__) listening = Listening() layout.addComponent(listening)
|
|
Removes a previously registered component event listener from this component.
|
|
Constructs a new IComponent.
|
Paints any needed component-specific things to the given UIDL stream. The more general paint method handles all general attributes common to all components, and it calls this method to paint any component-specific attributes to the UIDL stream.
|
Called when one or more variables handled by the implementing class are changed.
|
Gets currently set URI fragment. To listen changes in fragment, hook a IFragmentChangedListener. Note that initial URI fragment that user used to enter the application will be read after application init. It fires FragmentChangedEvent only if it is not the same as on server side.
|
Sets URI fragment. Optionally fires a FragmentChangedEvent
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sat Apr 20 16:01:28 2013 | http://epydoc.sourceforge.net |