DeleteWidgetAnnotationAction.js 850 B

1234567891011121314151617181920212223242526
  1. /*
  2. *+------------------------------------------------------------------------+
  3. *| Licensed Materials - Property of IBM
  4. *| IBM Cognos Products: Viewer
  5. *| (C) Copyright IBM Corp. 2001, 2012
  6. *|
  7. *| US Government Users Restricted Rights - Use, duplication or
  8. *| disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  9. *|
  10. *+------------------------------------------------------------------------+
  11. */
  12. /**
  13. * DeleteWidgetAnnotationAction - implements deleting existing annotations on the cognos viewer widget
  14. */
  15. function DeleteWidgetAnnotationAction() {}
  16. DeleteWidgetAnnotationAction.prototype = new AnnotationAction();
  17. DeleteWidgetAnnotationAction.prototype.execute = function()
  18. {
  19. var viewer = this.getCognosViewer();
  20. var widget = viewer.getViewerWidget();
  21. if (widget) {
  22. widget.getAnnotationHelper().deleteWidgetComment();
  23. }
  24. };