summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2010-10-29GDI: Implemented StringToHandle in TfpgGDIDrag classGraeme Geldenhuys
This is needed so we can store a string in a global buffer for DND. This will also reduce code duplication a bit, by simply allowing us to call this function.
2010-10-29Added a new private Drag property to TfpgGDIApplicationGraeme Geldenhuys
This allows use to easily find the TfpgDrag instance we are working with. Same was done in X11 backend.
2010-10-29Renamed TfpgMimeDataStruct to TfpgMimeDataItemGraeme Geldenhuys
* Also changed FormatCount to Count (more like standard list interface) * Also introduced a Items property (more like standard list interface) * The above to changes also made other implementations more simplified, so I did a bit of refactoring.
2010-10-28GDI: Implement last remaining part to allow DropTarget to receive data.Graeme Geldenhuys
2010-10-28GDI: store user selected information from DragEnter event handlerGraeme Geldenhuys
2010-10-28GDI: Choose a more specific base class for DropTarget reference.Graeme Geldenhuys
2010-10-28GDI: Reference to where I got info to implement Windows OLE DNDGraeme Geldenhuys
2010-10-28GDI: When creating a list of clipboard formats, add mime equivalents too.Graeme Geldenhuys
2010-10-28Implemented a bare minimum MimeType to Win Clipboard lookup function.Graeme Geldenhuys
2010-10-28GDI: Created a help function, GetFormatEtc, that sets up a TFormatEtc recordGraeme Geldenhuys
2010-10-28interface implementation methods can be private. We only work withGraeme Geldenhuys
the interface anyway, not an actual object instance.
2010-10-28GDI: Implemented HandleDNDLeave, DNDEnter and DNDPosition event handlersGraeme Geldenhuys
2010-10-28GDI: implemented a helper function for DropAction conversionGraeme Geldenhuys
2010-10-28GDI: Implemented DoDragLeave for droptargetGraeme Geldenhuys
2010-10-28GDI: Fixed DragEnter implementation.Graeme Geldenhuys
We should not modify the dwEffect variable before the user gets a chance to look at it.
2010-10-28GDI: implemented some helper functions for OLE DND clipboard typesGraeme Geldenhuys
2010-10-28Implemented equals (=) operator for TPoint typeGraeme Geldenhuys
2010-10-28GDI: Changed TfpgOLEDragDropEffect type to DWORD to match OLE APIGraeme Geldenhuys
2010-10-28GDI: Added OLE DND into TfpgGDIWindow.Graeme Geldenhuys
AcceptDrops: is implemented and can be toggled at runtime or designtime. Windows cursor also changes to show that target windows can accept drops.
2010-10-28GDI: A near complete Windows OLE Drag-n-Drop implementationGraeme Geldenhuys
2010-10-28TfpgWindowBase introduced a new abstract methodGraeme Geldenhuys
* This abstract method is called from TfpgWidget's AcceptDrops setter function * Template implementation in X11 * Actual implementation in GDI
2010-10-28Ad conversion helper functions from OLE DND to fpGUI DropActionsGraeme Geldenhuys
2010-10-28GDI: introduced a template TGDIDragManager classGraeme Geldenhuys
* implements the IDropTarget interface * Also initialize/uninitialize OLE at application startup/stop
2010-10-28extra error checking in mimelist DND operationGraeme Geldenhuys
2010-10-28More code comments and DNDDebug entries.Graeme Geldenhuys
2010-10-28bugfix: TfpgX11Drag.SendDNDDrop did not always process correctly.Graeme Geldenhuys
Even though this method was called, it should have checked the FDropAccepted variable which did didn't. Now it correctly conforms to the XDND spec. Due to the new behaviour we also have to make sure we free the TfpgDrag instance when the drop is not accepted.
2010-10-28Bugfix: TfpgX11Application.HandleDNDposition's XdndStatus message sent did ↵Graeme Geldenhuys
not correctly set the ActionType parameter if the drag was not accepted.
2010-10-28OnDragLeave event now has the Sender parameter set, and points to the target ↵Graeme Geldenhuys
component
2010-10-28TfpgDrag.Execute: replaced Assert() calls with Exceptions.Graeme Geldenhuys
This does error checking before and DND gets triggered. The error messages must still be replaced with resource strings though.
2010-10-28TfpgDrag.Execute now has a default TfpgDropAction drop action of daCopy.Graeme Geldenhuys
2010-10-27X11 DND: We never checked if drop was really accepted in HandleDNDDropGraeme Geldenhuys
If the Drop occured, but AcceptDrops = False, we must not do any Selections conversions. This is now so. We must still send the XdndFinished message though, so data object can be freed, and to simply comply with XDND protocol. We now correctly set the Accept or Decine status in the XDNDFinished message.
2010-10-27Renamed TfpgWindowBase.DoEnabledDrops() to DoDNDEnabled()Graeme Geldenhuys
This will hopefully reduce the confusion between the other TfpgWidget.AcceptDrops property - they had too similar names. * Applied rename changes to all other descendants too * Updated DND demo project
2010-10-27X11 DND: Incorrectly assumed there will always be a 'text/plain' mime-typeGraeme Geldenhuys
If the developer did not set the AMimeChoice in OnDragEnter, then the incorrect default could have been used. By default it used to deflaut to 'text/plain' and never actually checked the mime-type list to see if that exists. :-( Now the default AMimeChoice is set the the first mime-type in the mime-type list. This keeps with the methodology that the mime-type list must be from most specific to least specific mime types.
2010-10-26X11: in HandleDNDposition() we never recursed through all childrenGraeme Geldenhuys
The bug was that it only checked for the immediate children of the toplevel window. It never recursed through all levels of children finding the correct child the mouse cursor is over. This is now fixed. This also allows embedded frames or forms to work with DND.
2010-10-26X11: make sure that AcceptDrops are True before we fire OnDragDropGraeme Geldenhuys
There was a bug where if the component had a OnDragDrop event handler and AcceptDrops was False, it still triggered the event. Not any more.
2010-10-26X11: improved DND debug messagesGraeme Geldenhuys
I also made sure that all writeln() statements are wrapped in IFDEF's.
2010-10-25Improved event firing of OnDoubleClick and OnClickGraeme Geldenhuys
* Single click produces one OnClick event * On a Double Click in produces a OnClick, then a OnDoubleClick event. Old behaviour used to procuder yet another OnClick at the end. This is not needed. * OnMouseDown and OnMouseUp events behaviour has not changed. The reason we introduce the FOnClickPending instead of fully handling the events in TfpgWidget.MsgMouseUp is because a TfpgButton has slightly different behavior (eg: When clicking on a button, keep mouse down, and move mouse out of button rectangle, then an OnClick must not fire.) The extra FOnClickPending allows us to toggle this behaviour of HandleLButtonUp (which normally fires the OnClick event)
2010-10-21changed system color for all inactive color variables.Graeme Geldenhuys
This applies to: clInactiveSel, clUnset, clGridInactiveSel I wasn't fond of the purple / faded blue color from before.
2010-10-21GDI: Removed definition of MW_MOUSEWHEEL. it already exists in FPC.Graeme Geldenhuys
2010-10-15BaseNumericEdit NegativeColor property was used instead of field variable.Graeme Geldenhuys
The property does more that just set the color. It calls FormatEdit, which changes the color of TextColor property. This meant the parent color was never stored in FOldColor field variable.
2010-10-15BaseNumericEdit did not specify the default property color.Graeme Geldenhuys
By defining the default color, the UI Designer can omit that line in generated code, if the color did not change.
2010-10-15fpg_edit: removed pointless property declarationsGraeme Geldenhuys
Those properties are exactly the same visibility as inherited classes, so no point in simply listing them again. TextColor was the exception, it was public, so you can't decrease the visibility in descendants.
2010-10-15memo CursorLine property improvements and sanity checksGraeme Geldenhuys
* The selection variables were not updated before * Little error checking was done, so you could get index out of bounds errors.
2010-10-15Memo: introduced a new CursorPos propertyGraeme Geldenhuys
You can now set the Cursor X position via code.
2010-10-15Minor improvement in fpgCheckTimers procedure.Graeme Geldenhuys
2010-10-15fpgApplication.OnIdle was never triggered under Windows.Graeme Geldenhuys
2010-10-15TfpgMemo now has BeginUpdate and EndUpdate methodsGraeme Geldenhuys
This allows you to add/delete many lines and the memo only repaints once.
2010-10-12minor code formattingGraeme Geldenhuys
2010-10-12listbox: published a few more events and the Text propertyGraeme Geldenhuys
2010-10-12listbox: Text property is now a read/write propertyGraeme Geldenhuys