calling focusView with Web Author
Post here questions and problems related to oXygen frameworks/document types.
calling focusView with Web Author
Hello
I am trying to automagically expand the Validation side view after opening Web Author.
I am calling workspace.getViewManager().focusView('validation-panel-table') in my plugin.js but I get error
"workspace-22991562a3.js:3699 Uncaught TypeError: Cannot read property 'focus' of undefined
at sync.view.WorkspaceViewManager.focusView"
After the Editor is loaded I can call workspace.getViewManager().focusView('validation-panel-table') in browser console the Validation side view is expanded.
What is the proper place to call focusView? Is there another way to expand Validation side view?
Thanks,
Manu
I am trying to automagically expand the Validation side view after opening Web Author.
I am calling workspace.getViewManager().focusView('validation-panel-table') in my plugin.js but I get error
"workspace-22991562a3.js:3699 Uncaught TypeError: Cannot read property 'focus' of undefined
at sync.view.WorkspaceViewManager.focusView"
After the Editor is loaded I can call workspace.getViewManager().focusView('validation-panel-table') in browser console the Validation side view is expanded.
What is the proper place to call focusView? Is there another way to expand Validation side view?
Thanks,
Manu
-
- Site Admin
- Posts: 95
- Joined: Thu Jun 09, 2016 2:01 pm
Re: calling focusView with Web Author
Post by Gabriel Titerlea »
Hello,
To expand the validation side-view after opening a document you can use the EDITOR_LOADED event [1].
Best,
Gabriel
[1] https://www.oxygenxml.com/maven/com/oxy ... Event.html
To expand the validation side-view after opening a document you can use the EDITOR_LOADED event [1].
Code: Select all
goog.events.listen(workspace, sync.api.Workspace.EventType.EDITOR_LOADED, function(e) {
// You will have to use setTimeout because the side-views are shown immediately after the EDITOR_LOADED event.
setTimeout(function () {
workspace.getViewManager().focusView('validation-panel-table')
});
});
Gabriel
[1] https://www.oxygenxml.com/maven/com/oxy ... Event.html
Return to “SDK-API, Frameworks - Document Types”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service