Skip to content

DM-7029: fixed some api bugs #126

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 29, 2016
Merged

DM-7029: fixed some api bugs #126

merged 3 commits into from
Jul 29, 2016

Conversation

robyww
Copy link
Contributor

@robyww robyww commented Jul 28, 2016

  • Image is coming with one draw layer. (I can delete this draw layer and nothing changes on the image)
  • When draw layer is deleted, and no more layers are present, the layers dialog should be closed. (It stays with nothing to
    display, you have to click x to close it.)
  • After selecting an area in one viewer, I select an area in another viewer, then move the mouse to the first one:
147
    ImageViewerLayout.jsx:314 Uncaught TypeError: Cannot read property 'x' of null at ImageViewerLayout.jsx:314
Nothing works after
    that. I have to reload.
  • Selection appears with an offset, if the page, which contains the viewer is scrolled. (Load the attached script, press
    'Start selection tracking' click to select a point, then scroll page a bit down, then click to select another point - it shows
    down from where it should be.)
  • I have 2 image viewers in separate divs. Selected line in one, then selected line in the other. The line from the first one
    disappeared, but its label is still there. (See attached image.)
  • Selection is working differently from distance. To select in another plot, I need to press selection again. I don't need to press ruler again to select new distance in another plot.
  • The payload.attValue of CHANGE_PLOT_ATTRIBUTE action is using WorldPt for area and point selections (when payload.attKey is 'SELECTION' or 'ACTIVE_POINT'), but ImagePt for line selection (when payload.attKey is 'ACTIVE_DISTANCE') How can I make them
    all use image coordinates? Now exporting the coordinage system conversion code.

var imagePt= firefly.util.image.CCUtil.getImageCoords(plot,pt);

robyww added 2 commits July 28, 2016 16:30
 - Image is coming with one draw layer. (I can delete this draw layer and nothing changes on the image)
 - When draw layer is deleted, and no more layers are present, the layers dialog should be closed. (It stays with nothing to
  display, you have to click x to close it.)
 - After selecting an area in one viewer, I select an area in another viewer, then move the mouse to the first one:
147
  ImageViewerLayout.jsx:314 Uncaught TypeError: Cannot read property 'x' of null at ImageViewerLayout.jsx:314
Nothing works after
that. I have to reload.
 - Selection appears with an offset, if the page, which contains the viewer is scrolled. (Load the attached script, press
  'Start selection tracking' click to select a point, then scroll page a bit down, then click to select another point - it shows
down from where it should be.)
 - I have 2 image viewers in separate divs. Selected line in one, then selected line in the other. The line from the first one
  disappeared, but its label is still there. (See attached image.)
 - Selection is working differently from distance. To select in another plot, I need to press selection again. I don't need to
  press ruler again to select new distance in another plot.
- The payload.attValue of CHANGE_PLOT_ATTRIBUTE action is using WorldPt for area and point selections (when payload.attKey is
  'SELECTION' or 'ACTIVE_POINT'), but ImagePt for line selection (when payload.attKey is 'ACTIVE_DISTANCE') How can I make them
all use image coordinates? Now exporting the coordinage system conversion code.

var imagePt= firefly.util.image.CCUtil.getImageCoords(plot,pt);
@@ -31,6 +31,8 @@ export {RangeValues} from '../visualize/RangeValues.js';
export {WPConst, WebPlotRequest, findInvalidWPRKeys, confirmPlotRequest} from '../visualize/WebPlotRequest.js';
export {RequestType} from '../visualize/RequestType';
export {ExpandType, dispatchApiToolsView} from '../visualize/ImagePlotCntlr.js';
export {CsysConverter} from '../visualize/CsysConverter.js';
export {CCUtil} from '../visualize/CsysConverter.js';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To use CCUtil, we need to add the following exports:
export {primePlot} from '../visualize/PlotViewUtil.js';
export {visRoot} from '../visualize/ImagePlotCntlr.js';

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, I will do that too.

@tgoldina
Copy link
Contributor

tgoldina commented Jul 29, 2016

Thank you for quick turnaround. Most of the issues are fixed.

Here is what I have noticed:

  1. After using distance tool in one plot, then the other, clicking again in the first plot does not make it active. (You have to click on the border of the plot to make it active, clicking inside does not help.)

This seems to cause strange behavior, when selections do not work as expected. For example: select ruler, select some lines alternating first and second plot. Unselect ruler, select area icon. Selecting in the first plot will still show distance. I had to delete distance tool drawing layer or click on the border for things to start showing area selection.

In general, there is some confusion with active plot, when I have two viewers. Should a plot become active as soon as mouse enters is? Otherwise in readout, compass thumbnail will still show active plot, while readout thumbnail could use another plot.

  1. In Selection Tool drawing layer the help text is so long that 'Delete' link is not visible. The text is also cut.

@robyww
Copy link
Contributor Author

robyww commented Jul 29, 2016

With selection, there is no delete. The drawing layers make that stuff optional. I can turn it on.

@robyww
Copy link
Contributor Author

robyww commented Jul 29, 2016

#1 is a little beyond the scope of this ticket. I will make new ticket from it. DM-7068

@tgoldina
Copy link
Contributor

Thank you. Then it's ready to merge.

2016-07-29 15:13 GMT-07:00 Trey Roby [email protected]:

#1 #1 is a little beyond
the scope of this ticket. I will make new ticket from it.


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#126 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/ALU3QD0kPxPF6D4ruiMyzZWcHEl90CGAks5qanscgaJpZM4JXvr2
.

@robyww robyww merged commit db9962b into dev Jul 29, 2016
@robyww robyww deleted the dm-7029-api-bugs branch July 29, 2016 22:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants