Jump to content


Photo

Disabling context menu on UniHTMLMemo

UniHTMLMemo Context Menu

  • Please log in to reply
9 replies to this topic

#1 arilotta

arilotta

    Advanced Member

  • uniGUI Subscriber
  • PipPipPipPip
  • 100 posts
  • LocationTrieste, Italy

Posted 13 June 2018 - 07:43 AM

Hi all,

it seems that the MainModule option "boDisableMouseRightClick" does not affect UniHTMLMemo and UniDBHTMLMemo components.

Even if I add that option, the context menu appears with right button click.

Is there any workaround ?

Thanks

Andrea

 


  • 0

#2 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 4987 posts

Posted 13 June 2018 - 07:53 AM

Hi,

 

Have you tried this approach?:

http://forums.unigui...enu/#entry52146


  • 0

#3 arilotta

arilotta

    Advanced Member

  • uniGUI Subscriber
  • PipPipPipPip
  • 100 posts
  • LocationTrieste, Italy

Posted Yesterday, 07:20 AM

Hi Delphi Dev, sorry for the delay. I've tried the solution in the linked thread,

unfortunately it does not seem to work.


  • 0

#4 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 4987 posts

Posted Yesterday, 07:47 AM

Hi,

 

Can you make a simple testcase if possible ?!


  • 0

#5 arilotta

arilotta

    Advanced Member

  • uniGUI Subscriber
  • PipPipPipPip
  • 100 posts
  • LocationTrieste, Italy

Posted Yesterday, 10:06 AM

Sure, here you are Delphi Dev, please find it in the attachment.

I have also set "boDisableMouseRightClick" on MainModule, but the context menu still appears

on UniHTMLMemo.

 

Thanks

Andrea

Attached Files


  • 0

#6 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 4987 posts

Posted Yesterday, 10:56 AM

Ok,

 

Thanks for the testcase

 

Which browser are you using?!


  • 0

#7 arilotta

arilotta

    Advanced Member

  • uniGUI Subscriber
  • PipPipPipPip
  • 100 posts
  • LocationTrieste, Italy

Posted Yesterday, 11:16 AM

Hi Delphi Dev, Chrome.

 

Andrea


  • 0

#8 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 4987 posts

Posted Yesterday, 12:27 PM

I will test it and let you know


  • 0

#9 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 4987 posts

Posted Yesterday, 01:04 PM

Can you also try this approach ?

 

function initialize

function initialize(sender, eOpts)
{
    sender.iframeEl.el.dom.contentWindow.oncontextmenu=function(){
        return false
    };
}

  • 0

#10 arilotta

arilotta

    Advanced Member

  • uniGUI Subscriber
  • PipPipPipPip
  • 100 posts
  • LocationTrieste, Italy

Posted Yesterday, 01:41 PM

Yeeesss, it works ! 

Great Delphi Dev

 

Thank you

Andrea


  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users