Attach vb-event on brick start/stop

Bug #773478 reported by Abbakus
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Virtualbricks
Fix Released
Medium
Abbakus

Bug Description

Can be useful to have a vb-event per-brick attached to the bricks start/stop event.

This event should be configurable via GUI as well as vb-shell.

Abbakus (abbakus)
Changed in virtualbrick:
assignee: nobody → Abbakus (abbakus)
milestone: none → 0.4
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
Abbakus (abbakus) wrote :

Partially implemented on revision 249: (command line only)

>switch_name config pon_vbevent=event_name
>switch_name config poff_vbevent=event_name2

The event can be a real-shell event, so it's possibile to add a script file to execute (as requested by Francesco).

For example:
>new event event_name
>event_name config addsh ~/myscript.sh
>event_name config delay=3

>switch_name on //switch_name is started and event_name is started too. After 3 seconds ~/myscript.sh is executed.
>switch_name off //switch_name is started and event_name2 is started.
>switch_name config pon_vbevent= //power on event is cleared

Revision history for this message
Francesco Apollonio (lorddex) wrote :

Yes It's really useful! I've already planned to add something like this because if events allow also to launch bash script instead of vb shell commands we can use this start/stop signal to launch some scripts when a brick starts/stops! It will be great!

Revision history for this message
Abbakus (abbakus) wrote :

Implemented GUI management on rev. 253.

Right click on a brick -> Attach Event -> ...

A minor bug still exist: configuring events for a brick with "empty" events, the first time you open the dialog window, the first row results selected while none should be selected. I cannot understand why.

Changed in virtualbrick:
status: In Progress → Fix Released
status: Fix Released → Fix Committed
Revision history for this message
Francesco Apollonio (lorddex) wrote : Re: [Bug 773478] Re: Attach vb-event on brick start/stop

great job!
It works well for me and I haven't noticed the bug!
This is a wonderful feature! :D

Francesco

Revision history for this message
Abbakus (abbakus) wrote :

:-)

To verify the BUG:
1) Create a new switch.
2) Close VB.
3) Open VB.
4) Right click on new brick -> Attach Event

=> The first row is selected while none should be.

Changed in virtualbrick:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.