This topic contains 1 reply, has 2 voices, and was last updated by  Dimitar 10 years, 7 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Tooltip state #29927

    mijus
    Participant

    Is it possible to check if jqxTooltip is open?

    Tooltip state #29954

    Dimitar
    Participant

    Hello mijus,

    You can check the state of a tooltip by binding to the open and close events. Here is how:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <link rel="stylesheet" type="text/css" href="../../jqwidgets/styles/jqx.base.css" />
    <script type="text/javascript" src="../../scripts/jquery-1.10.2.min.js"></script>
    <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script>
    <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script>
    <script type="text/javascript" src="../../scripts/gettheme.js"></script>
    <script type="text/javascript">
    $(document).ready(function () {
    var theme = "";
    $("#filmPicture1").jqxTooltip({ content: 'The Amazing Spider-man', position: 'left', name: 'movieTooltip', theme: theme });
    var isOpened = false;
    $("#filmPicture1").on("open", function () {
    isOpened = true;
    });
    $("#filmPicture1").on("close", function () {
    isOpened = false;
    });
    });
    </script>
    </head>
    <body>
    <div style="margin-left: 200px; width: 400px;" id="container">
    <img style="margin: 8px;" src="../../images/The_Amazng_Spider_Man.jpeg" id="filmPicture1" />
    </div>
    </body>
    </html>

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.