Page 8 of 9

Posted: Thu Feb 08, 2007 11:34 am
by srod
Konne wrote:Uhh, works with Vista.
Anyways srod can you help me with this question?
http://www.purebasic.fr/english/viewtop ... 24cd240e5d
Done. I have replied to the post with an example. :)

Posted: Thu Feb 08, 2007 3:45 pm
by Konne
thx

Posted: Thu Jun 28, 2007 9:30 am
by Niffo
What about a Linux version ? :))

Posted: Thu Jun 28, 2007 10:29 am
by srod
Niffo wrote:What about a Linux version ? :))
Great idea. As soon as you finish it, then please let me know!

:)

Posted: Sun Jul 01, 2007 7:15 pm
by srod
Bug fix. 01/07/07.

More of an omission than a bug (with panel gadgets) but it has been fixed.

:)

Posted: Mon Jul 02, 2007 8:28 am
by Niffo
When trying to download :
"The page cannot be found" :(

Posted: Mon Jul 02, 2007 8:36 am
by Sveinung
I get the same as Niffo

Sveinung

Posted: Mon Jul 02, 2007 10:29 am
by srod
Sorry! :oops: Uploaded the wrong file!

Posted: Mon Jul 02, 2007 12:14 pm
by GeoTrail
Hey Sveinung, are you who I think you are? :)

Posted: Tue Aug 07, 2007 1:49 am
by srod
Update - 6th August 2007. EasyVENT 2.0

This sees the removal of the 'in-house' drag and drop code for far simpler and more powerful handlers which utilise PB's new OLE drag and drop library (my thanks to Freak for this). This means that you can use EasyVENT to now drag and drop between applications and drag more than just text etc.

Although the drag/drop handlers are little more than a wrapper around the PB drag/drop library, EasyVENT does make dragging from ANY gadget/window very easy; easier than would otherwise be the case. This is because EasyVENT's #OnDragItemStart handlers can be attached to any gadget/window as opposed to PB's #PB_EventType_DragStart event type which fires for just a few types of gadget etc.

There are two demos in the EasyVENT 2.0 package which show just how much easier this is now than was the case with EasyVENT 1.0. In fact you can run both demos simultaneously and drag from one to the other quite merrily!

Note that if a drag image is required then you need to set a drag callback in your #OnDragItemStart handler.

Please see the first post for the downloads.

Posted: Fri Sep 14, 2007 8:40 pm
by srod
Update: 14th September 2007. Version 2.01.
This is a minor update.

Have extended the scope of the event #OnItemSelected. Basically this event can be used with various gadget types, but now with ListIcons it will fire under the following circumstances :

i) an item has been selected, ii) an item has been deselected, iii) a checkbox (for those ListIcons with checkboxes in the 1st column) has been cleared, iv) a checkbox (for those ListIcons with checkboxes in the 1st column) has been checked.

iii) and iv) represent the extension of this event.

Please see the help manual and/or the ListIcon demo program for more details.

(Before anyone asks; a similar Event regarding checkboxes in TreeGadgets is not supported under Windows prior to Vista and so I have not included it in this version of EasyVENT. Still, it is not difficult to hack up some code to determine whether the user clicked a checkbox in a TreeGadget etc.)

Please see the first post for the revised download.

I think there may be a bug with EasyVents drag and drop code

Posted: Tue Sep 18, 2007 4:14 pm
by DoubleDutch
I think there may be a bug with EasyVents drag and drop code. Here is the section with the possible bug (Event Dispatcher):

Code: Select all

   Case #PB_Event_GadgetDrop, #PB_Event_WindowDrop
;Now call default procedure.
      text$="EVENT_oldproc"
      result2 = GetProp_(hwnd, @text$)
      If result2 
        result= CallWindowProc_(GetProp_(hwnd, @text$), hWnd, uMsg, wParam, lParam) 
      EndIf

      If result
	      result = CallWindowProc_(result, hWnd, uMsg, wParam, lParam)
	    Else
	    	Debug("Zero returned!!!  On WindowsMe => crash!")
	    EndIf
	    
      If uMsg = #PB_Event_WindowDrop
        sender\hWnd = WindowID(wParam)
      Else
        sender\hWnd = GadgetID(wParam)
      EndIf
      pt\x = DesktopMouseX() : pt\y = DesktopMouseY()
      MapWindowPoints_(0, sender\hWnd, pt, 1)
      sender\mousex = pt\x
      sender\mousey = pt\y
      sender\button = #Event_LeftButton
      sender\message = #OnDropItem
      sender\item = EVENT_globals\gDragFrom
      EventCallHandler(@sender,result, @mesent) 
      ProcedureReturn result
I've marked what happens with a comment. The value for result seems to be zero all the time for a drag/drop? Have I initialised something incorrectly?

The zero does not crash XP or Vista, but does crash machines <NT.

Posted: Tue Sep 18, 2007 6:15 pm
by srod

Code: Select all

If result 
         result = CallWindowProc_(result, hWnd, uMsg, wParam, lParam) 
       Else 
          Debug("Zero returned!!!  On WindowsMe => crash!") 
       EndIf 
Where that code has come from is beyond me and the only surprising thing is that EasyVENT does not crash on all systems!

Simply remove those lines and it should work. I'm uploading a new version now.

Thanks.

Posted: Tue Sep 18, 2007 7:37 pm
by DoubleDutch
Do you mean the actual check for zero?

I put in the check for zero, if there is no check then it will crash on <NT.

-Anthony

Posted: Tue Sep 18, 2007 7:40 pm
by srod
No and yes!

Some of that code I cannot even find in my version of EasyVENT!

Remove all of:

Code: Select all

If result 
  result = CallWindowProc_(result, hWnd, uMsg, wParam, lParam) 
Else 
   Debug("Zero returned!!!  On WindowsMe => crash!") 
EndIf 
It has no place in the library.