Jump to content

Disabling context menu in UniURLFrame


Rav

Recommended Posts

21 minutes ago, donlego said:

even with local source the right clisk is still appear on firefox and chrome

     FUniUrlFrame.URL:='/files/akun.html';

Also try this:

      //FUniUrlFrame.ClientEvents.ExtEvents.Add('frameload = function frameload(sender, frame, eOpts){  sender.iframe.contentWindow.window.oncontextmenu = function(){return false}}');
      FUniUrlFrame.ClientEvents.ExtEvents.Values['frameload'] := 'function frameload(sender, frame, eOpts){  sender.iframe.contentWindow.window.oncontextmenu = function(){return false}}';

 

Link to comment
Share on other sites

 FUniUrlFrame.ClientEvents.ExtEvents.Values['frameload'] := 'function frameload(sender, frame, eOpts){  sender.iframe.contentWindow.window.oncontextmenu = function(){return false}}';

the code work well on ff and chrome , if the url is html , but if the url pdf file it appears again

how to work well both on html files and pdf file

pdf on chrome work , but not on ff

Link to comment
Share on other sites

56 minutes ago, donlego said:

  FUniUrlFrame.URL:='/files/akun.pdf';

The document is being shown by the PDF viewer installed on the client machine and you have no idea what that viewer is and there is no universal way to disable right click...

Link to comment
Share on other sites

37 minutes ago, Sherzod said:

You can use UniPDFFrame in parallel and catch the contextmenu there.

There were solutions on the forum, if I'm not mistaken.

O, i think for now it enough, thanks very much @Sherzod, sory make u busy with my question 

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...