Plugin GetAbsXY (krpano extends)

  • Hi!
    I wish to share plugin for free
    it's plugin for geting absolute x and y of any plugin.
    For example, you have many plugin that included eachother and has various of align and edge and x/y.
    But you want to know plugin absolute x in stage coordinates.
    Then this plugin (getabsxy) will help you.

    Initiate (it will add new getabsxy object into krpano):

    Code
    <plugin name="anyname" preload="true" url="getabsxy.swf" alturl="getabsxy.js" />

    And usage:

    Code
    getabsxy.getx(absx, name);trace(absx);
    getabsxy.getx(absy, name);trace(absy);


    Where:
    absx/absy - any variable for coordinate value store
    name - is the target plugin/layer name

    Enjoy
    Andrey *thumbup*

  • Hi Andrew,

    yes, PERFECT.... *thumbsup* *thumbsup* *thumbsup*
    THANK YOU...

    I´m developing a webpage based on the Player, inside a scrollable textarea I have an InputTextField, which must be moved to the correct position on mobiles caused by the keyboard...
    And you`re PlugIn was solving my problem... *thumbup*

    Good work, an absolute MUST HAVE PlugIn for coders... *love*
    THANKS ONE MORE TIME...
    Steve

  • Hi Andrew,

    okay, working with you`re plugin and found out some interesting things:
    Works fine if the plugin is in one or two parent elements, but I have one plugin which has 3 parent Elements (the last/third parent Element is a scrollArea...) and then I got an error message:

    ERROR: getabsxy plugin v1.0: gety - plugin pugin[txtContainer_scrollarea] not found
    The only value I got then is the y-Value of the plugin, based on the scrollarea...

    But I need the absolute XY Coordinates....????

    Could it be solved, if you give a "path" trough the parent Elements to get my absXY?

    Any help is welcome... *smile*
    Steve

  • Hi!
    it's doesn't metter how many parents
    But I didn't test it with scrollarea
    Scrollarea is a special plugin, perhaps it is a reason.

    Andrey

    PS - not sure I can solve it.
    But I can recomend you try my draggablelayer plugin for scrolling or simple dragging layers

  • Andrew thanks for having a look at it!

    Yes, I´m using the krpano scrollarea plugin which is really very smooth even on touchdevices...

    Righht now I´m measuring from the last "reachable" layer (the layer which is NOT in the scrollarea) to my target layer to get the absX/Y Coordinates, some more maths, but then I got my Value...

    Would be fine if you could manage that problem, you have written a very useful PlugIn, should be a part of Klaus Player... *wink*

    best regards,
    Steve

  • Hello!

    I just tested it with KRPano 1.17-2 (I did not try with previous version though) and when I ask a "PanoTour Thumbnail Item" for its position, I got "NaN".

    A thumb item is plugin in a plugin in a plugin. Sometimes (on hover), the item is scaled.

    Does this is the known "scaled" or "2 or more parents" issue?

    Regards,

    Paul

    « Quidquid latine dictum sit, altum sonatur »
    Pentax stuff.

  • Hi! :)

    Thanks Hernan for the plugin, but I'm broke and I resolved for a free plugin :) The point with free plugins is that it happens they do not work as expected ;)
    One good thing with your's Hernan, is that it deals with hotspot, too :)

    Actually, Andrey's one is working fine for a bunch of items in my pano but not for the ones I need it :)

    Here is the code for the items: (if Andrey has time to check and update his work...)

    Regards,

    « Quidquid latine dictum sit, altum sonatur »
    Pentax stuff.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!