<div dir="ltr">If indeed that list is missing those event, please do a PR.<div><br></div><div>Thx!</div><div><br></div><div>Seb </div></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Sep 14, 2018 at 2:59 PM Rick Frank <<a href="mailto:rickfrank@me.com">rickfrank@me.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div text="#000000" bgcolor="#FFFFFF">
    <p><br>
    </p>
    <p>It's a UI decoupling  model - view kind of thing....<br>
    </p>
    <p>in our interactorStyleSlice subclass, we want to update the slice
      number on the UI.</p>
    <p>This means setting the text in the div element, which we don't
      want to expose directly in the interactor.</p>
    <p>So, when the observer gets the interaction event on a mouse
      wheel, it then brokers to the UI to update the current slice by
      fetching the current slice from the data model....</p>
    <p>I was able to fix it by adding </p>
    <p>....................<br>
    </p>
    <p>'Move3D',<br>
        'StartInteractionEvent',<br>
        'InteractionEvent',<br>
        'EndInteractionEvent',</p>
    <p>to the end of the events and then calling</p>
    <p>viewportData.pluginData.observer  =
      VTKUtils.ohifInteractorObserver.newInstance();<br>
 viewportData.pluginData.observer.setInteractor(ourSliceInteractorStyle);<br>
       viewportData.pluginData.observer.setEnabled(1);<br>
    </p>
    <p><br>
    </p>
    <p>and now my observer gets the events.<br>
    </p>
    <p>I can push that change and do a pull request if you think that's
      the correct fix.</p>
    <p><br>
    </p>
    <p>Thanks</p>
    <p>Rick</p>
    <p><br>
    </p>
    <p><br>
    </p>
    <br>
    <div class="m_-6730035472641075775moz-cite-prefix">On 09/14/2018 05:34 PM, Sebastien
      Jourdain wrote:<br>
    </div>
    <blockquote type="cite">
      
      <div dir="ltr">I guess the question is what do you want to do with
        handleInteractionEvent ?<br>
        <div><br>
        </div>
        <div>It is true that no code is using it, but mostly because
          there is not much usage of it right now. Usually we care of a
          mousePress or else.</div>
      </div>
      <br>
      <div class="gmail_quote">
        <div dir="ltr">On Fri, Sep 14, 2018 at 2:29 PM Rick Frank <<a href="mailto:rickfrank@me.com" target="_blank">rickfrank@me.com</a>>
          wrote:<br>
        </div>
        <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
          <div text="#000000" bgcolor="#FFFFFF">
            <p>The interactor styles Invoke the events.....</p>
            <p><br>
            </p>
            <p>  case States.IS_PAN:<br>
                      publicAPI.handleMousePan(renderer, pos);<br>
                      publicAPI.invokeInteractionEvent({ type:
              'InteractionEvent' });<br>
                      break;</p>
            <p><br>
            </p>
            <p>etc</p>
            <p><br>
            </p>
            <p>but I can't find an example of a receiver (observer) of
              the InteractionEvent....</p>
            <p><br>
            </p>
            <p>somewhere that implements handleInteractionEvent....</p>
            <p>I searched vtk.js for handleInteractionEvent and didn't
              find anything...</p>
            <p>?<br>
            </p>
            <p>Thanks</p>
            <p><br>
            </p>
            <p>Rick</p>
            <p><br>
            </p>
            <p><br>
            </p>
            <p><br>
            </p>
            <br>
            <div class="m_-6730035472641075775m_-663974758945233322moz-cite-prefix">On
              09/14/2018 05:14 PM, Sebastien Jourdain wrote:<br>
            </div>
            <blockquote type="cite">
              <div dir="ltr">Your interactorObserver only need to
                implement handleStartInteractionEvent,
                handleInteractionEvent, handleEndInteractionEvent.
                <div>They will automatically be linked.<br>
                  <div><br>
                  </div>
                  <div>Look at any other InteractorStyle implementation
                    if need be.</div>
                </div>
                <div><br>
                </div>
                <div>Seb</div>
              </div>
              <br>
              <div class="gmail_quote">
                <div dir="ltr">On Fri, Sep 14, 2018 at 2:06 PM Rick
                  Frank <<a href="mailto:rickfrank@me.com" target="_blank">rickfrank@me.com</a>>
                  wrote:<br>
                </div>
                <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                  <div text="#000000" bgcolor="#FFFFFF">
                    <p>Thanks.</p>
                    <p><br>
                    </p>
                    <p>This event list seems to be missing</p>
                    <p><br>
                    </p>
                    <p>const START_INTERACTION_EVENT = { type:
                      'StartInteractionEvent' };<br>
                      const INTERACTION_EVENT = { type:
                      'InteractionEvent' };<br>
                      const END_INTERACTION_EVENT = { type:
                      'EndInteractionEvent' };<br>
                    </p>
                    <br>
                    and so function
                    vtkInteractorObserver::subscribeToEvents() {)<br>
                    <br>
                    doesn't get them.<br>
                    <br>
                    I think this is a bug, or am I missing something?<br>
                    <br>
                    I'm trying to create an interactor observer and I
                    can get the interaction events....<br>
                    <br>
                    <br>
                    Thanks<br>
                    <br>
                    Rick<br>
                    <br>
                    <br>
                    <div class="m_-6730035472641075775m_-663974758945233322m_-3347050549355893865moz-cite-prefix">On
                      09/13/2018 02:12 PM, Sebastien Jourdain wrote:<br>
                    </div>
                    <blockquote type="cite">
                      <div dir="ltr">
                        <div dir="ltr">I think it is named MiddleButton.
                          You can find the full list here:
                          <div><a href="https://github.com/Kitware/vtk-js/blob/master/Sources/Rendering/Core/RenderWindowInteractor/index.js#L28-L56" target="_blank">https://github.com/Kitware/vtk-js/blob/master/Sources/Rendering/Core/RenderWindowInteractor/index.js#L28-L56</a><br>
                          </div>
                        </div>
                      </div>
                      <br>
                      <div class="gmail_quote">
                        <div dir="ltr">On Thu, Sep 13, 2018 at 11:00 AM
                          Rick Frank <<a href="mailto:rickfrank@me.com" target="_blank">rickfrank@me.com</a>>
                          wrote:<br>
                        </div>
                        <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                          <div text="#000000" bgcolor="#FFFFFF"> For the
                            time being I have a subclass of
                            vtkInteractorStyleTrackballCamera which is a
                            crib of vtkInteractorStyleSlice for handing
                            slice views....<br>
                            <br>
                            <br>
                            I can get:<br>
                            <br>
                             publicAPI.handleRightButtonPress =
                            (callData) => {<br>
                                    const pos = callData.position;<br>
                                    model.previousPosition = pos;<br>
                                    publicAPI.startDolly();<br>
                                };<br>
                            <br>
                            to override RightButton<br>
                            <br>
                            but there doesn't seem to be a<br>
                            <br>
                             publicAPI.handleCenterButtonPress =
                            (callData) => {<br>
                                 ....<br>
                                };<br>
                            <br>
                            <br>
                            ....<br>
                            <br>
                            Am I missing something on how to get the
                            center button? I can get the wheel....<br>
                            <br>
                            <br>
                            Thanks<br>
                            <br>
                            Rick<br>
                            <br>
                            <br>
                            <div class="m_-6730035472641075775m_-663974758945233322m_-3347050549355893865m_-7190038227117689756moz-cite-prefix">On
                              09/13/2018 01:21 PM, Sebastien Jourdain
                              wrote:<br>
                            </div>
                            <blockquote type="cite">
                              <div dir="ltr">The manipulator
                                infrastructure come from ParaView and
                                has never been pushed to VTK on the c++
                                side.
                                <div>Anyhow, we have a ManipulatorStyle
                                  on which we register a bunch of
                                  manipulators to custom build our style
                                  binding (pan on left-button, rotate on
                                  left-button+Alt, ...). </div>
                                <div>That's the high level concept.</div>
                                <div><br>
                                </div>
                                <div>So either you provide a XXXXStyle
                                  that should handle everything or use a
                                  ManipulatorStyle on which you register
                                  manipulators...</div>
                                <div><br>
                                </div>
                                <div><br>
                                </div>
                              </div>
                              <br>
                              <div class="gmail_quote">
                                <div dir="ltr">On Thu, Sep 13, 2018 at
                                  10:02 AM Rick Frank via vtkusers <<a href="mailto:vtkusers@public.kitware.com" target="_blank">vtkusers@public.kitware.com</a>>
                                  wrote:<br>
                                </div>
                                <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
                                  <br>
                                  I'm using vtkInteractorStyleImage and
                                  notice that I don't have access to <br>
                                  a center mouse down (for Pan)...<br>
                                  <br>
                                  <br>
                                  but the Manipulators have center mouse
                                  down...<br>
                                  <br>
                                  <br>
                                  Manipulators seems to be a new thing
                                  in the vtk.js<br>
                                  <br>
                                  <br>
                                  How do they relate to the interactors?
                                  Is there a way to get a center <br>
                                  mouse down in my interactorStyleImage
                                  subclass<br>
                                  <br>
                                  <br>
                                  Rick<br>
                                  <br>
                                  <br>
                                  <br>
_______________________________________________<br>
                                  Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
                                  <br>
                                  Visit other Kitware open-source
                                  projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
                                  <br>
                                  Please keep messages on-topic and
                                  check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
                                  <br>
                                  Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
                                  <br>
                                  Follow this link to
                                  subscribe/unsubscribe:<br>
                                  <a href="https://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">https://public.kitware.com/mailman/listinfo/vtkusers</a><br>
                                </blockquote>
                              </div>
                            </blockquote>
                            <br>
                          </div>
                        </blockquote>
                      </div>
                    </blockquote>
                    <br>
                  </div>
                </blockquote>
              </div>
            </blockquote>
            <br>
          </div>
        </blockquote>
      </div>
    </blockquote>
    <br>
  </div>

</blockquote></div>