Samples of events tcl/tk - events

Where can I find a list of all the samples of events for the command "bind" in TCL?
#For example:
bind .listbox <<ListboxSelect>> {...}

The various virtual events are documented in each widget's manual page.
Since the virtual events can be defined and configured by any widget, and some virtual events are defined and used internally by widgets, there's no easy way to create a master list.

Related

Nightwatch Page Object hierarchy/re-use

I'd like to use Nightwatch's Page Objects system for UI components used across our app. Because nightwatch has their own way of reading/initializing them, I don't see a way of properly extending/re-using them.
For example I want an DateInputPageObject for "date fields". It would identify the label, input, date picker, etc.
I'd use it on any page with a date input field.
I would also like to extend page objects. For example, class FooModal extends Modal. The ModalPageObject would define selectors for elements all modals have - the overlay, container, close button, etc.
I can't find any way to do this in nightwatch, is it possible at all?
The problem is not with nightwatch per se as it's just following the basic structure of page object model BUT that is a very good question and it brings out one of the drawbacks of page object model.
Page object model has been around for some time and the problem with that is that it doesn't serve the needs of modern web applications that use component libraries & living style-guides and re-using components.
Personally I found it easier to use a global json file with all the components structured based on their type. e.g. labels, fields, buttons, etc.

Simile Timeline change order of lines

How do I change the vertical order of event lines in Simile Timeline? Where in the code does it decide what order to put them in?
I have tried looking into this also. I am convinced it is random order.
This not the answer you wanted but try using this timeline
http://almende.github.io/chap-links-library/timeline.html
It is quite flexible, you can choose your create your own layout and use your own CSS/HTML in each individual event.
Edit: Found a attribute that you could use to change the order
trackNum - used to override the automatic layout of events on the
Timeline.
check this wiki for more info: http://simile-widgets.org/wiki/Timeline_EventSources
under "Event Attributes for Developers"

Joomla 3 Article alternative layout

I've created an alternative layout for one of my articles which can be applied successfully, but as has been highlighted in various forums: if you view the article using the Single Article menu type the alternative layout doesn't get applied because of an XML override.
I have a Joomla site that is setup for Sales and Support where the article info such as date, hits etc is useful but on the marketing side none of that is needed, hence an alternative layout would work well.
I want to know how to enable my alternative layout using the Single Article menu type - I've already got the layout how I want it (testing it by having it overwrite default.php) but want to set it up as marketing.php instead and only have it applied to what is needed.
You're probably not going to like this answer because you have already written you're alternate view. If you were rewriting it to begin with, why would you not write in a way that the side bar parameters (date, hits, ect) are within a container that is only loaded conditionally. This way you would only have one view to worry about and a lot less headaches.

Backbone.js DOM events full list

Anyone knows where I could find a complete list of built-in DOM events in Backbone.js? I managed to guess some fancy ones like "mouseout", but just a complete list would be very helpful. Not available in official docs or google.
Thanks!
Backbone's DOM event for Views (which is what I'm assuming you're talking about) come from jQuery or ZeptoJS (whichever one you are using). Any valid event from either of those libraries, is a valid event in a Backbone view.
http://api.jquery.com/category/events/
http://zeptojs.com/

Drag&Drop list that sets model properties based on order?

I'm trying to implement a list of items on a web page in which each item on the list is reorder-able via drag and drop. The current placement of an item within the list should set an 'interest' property on the item's model.
I've never built anything like this before and not really sure where to start or what approach to take. Any guidance would be very helpful!
You can use acts_as_list gem to simplify reorder process at backend, and jQuery.sortable at frontend
I found this walkthrough which was very helpful:
http://webtempest.com/sortable-list-in-ruby-on-rails-3-almost-unobtrusive-jquery/

Resources