sketchucation logo sketchucation
    • Login
    🛣️ Road Profile Builder | Generate roads, curbs and pavements easily Download

    Proxy Tools

    scheduled pinned locked moved Developers' Forum
    4 Posts 3 Posters 384 Views 3 Watching
    loading-more-posts
    • oldest-to-newest
    • newest-to-oldest
    • most-votes
    reply
    • reply-as-topic
    guest-login-reply
    deleted-message
    • AdamBA Offline
      AdamB
      last edited by

      I'm sure this one has been discussed before, but I can't find the thread..

      I know we mere mortals cannot create instances of the standard SU tools, but can we delegate messages to them?

      I'm think it would be neat to have a custom tool be able to have mode where it was just acting as a Proxy and forwarding all onLButtonDown/onMouseMove etc to another tool.

      Adam

      Developer of LightUp Click for website

      one-reply-to-this-post last-reply-time reply quote 0
      • tbdT Offline
        tbd
        last edited by

        what is the difference in creating a tool and handling the buttons/movement/keyboard ?

        SketchUp Ruby Consultant | Podium 1.x developer
        http://plugins.ro

        one-reply-to-this-post last-reply-time reply quote 0
        • P Offline
          psychomuffin
          last edited by

          When you say create instances of the the standard SU tools, it makes me think of the custom toolbar script. You can make a toolbar with any of the original SU commands, in any order, combo, even put the little verticle breaks where you want. I forget the link, its somewhere here. I'm not sure if this is what you're asking though.

          one-reply-to-this-post last-reply-time reply quote 0
          • AdamBA Offline
            AdamB
            last edited by

            I mean I want to create a tool that code-wise looks like this:

            class MyProxyTool
            
              def onMouseMove(flags, x, y, view)
                <pseudo-code> 
                   call the SU movetool with (flags,x,y,view) arguments 
                </pseudo-code>
              end
            
              .. and so on ..
            end
            

            So its a tool that just passes everything onto the Movetool (for example) to allow it to "do its stuff".

            Does that make sense?

            Adam

            Developer of LightUp Click for website

            one-reply-to-this-post last-reply-time reply quote 0
            • 1 / 1
            • first-post
              last-post
            Buy SketchPlus
            Buy SUbD
            Buy WrapR
            Buy eBook
            Buy Modelur
            Buy Vertex Tools
            Buy SketchCuisine
            Buy FormFonts

            Advertisement