ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 TImageEnMView popup menu not shown

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
PeterPanino Posted - Dec 15 2023 : 11:06:35
I have assigned a popup menu to my TImageEnMView at design-time:



However, when I right-click an image on the TImageEnMView, the popup menu is not shown!

Even when setting the PopupMenus property to any value, it does not show the popup menu.

When I show the popup menu in the MouseDown event handler, the right-clicked image is not selected before the popup menu is displayed:

procedure TForm1.ImageEnMView1MouseDown(Sender: TObject; Button: System.UITypes.TMouseButton; Shift: TShiftState; X, Y: Integer);
var
  ScreenPoint: TPoint;
begin
  if Button = Vcl.Controls.mbRight then
  begin
    // Get the index of the image cell at the mouse position?
    // ImageEnMView1.SelectImage(ImageEnMView1.MouseDownThumbIndex);

    // Convert the mouse position of the clicked control to screen coordinates:
    ScreenPoint := ImageEnMView1.ClientToScreen(Point(X, Y));
    // Show the popup menu at the mouse position:
    PopupMenuOptions.Popup(ScreenPoint.X, ScreenPoint.Y);
  end;
end;


How to solve this dilemma?

(BTW, the term MouseDownThumbIndex is not found in the CHM documentation).
1   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - Dec 15 2023 : 18:45:28
Hi Peter

I'm not seeing that. Can you reproduce it in any of our ImageEnMView demos?



Nigel
Xequte Software
www.imageen.com