open a second dialog window from the already opened dialog window - primefaces

I open a dialog window in my application. After that I would like to open a second dialog from the existing dialog window. The second dialog opens inside the first dialog. The problem arise when the second dialog size is greater than the first one. In that case the second dialog does not appear in the full size but is limited to the size of the first window.
What should I do to display the second dialog window in the whole size?
Best regards,
Javanus

This might be called a workaround , but...
you always can do something like
<p:commandLink value="hide first, show second" onclick="dlg1.hide();dlg2.show();" />
(hide first dialog and open the second)
and in the second dialog set onHide="dlg1.show()"

Related

Show editor and output at the same time

When using the octave-IDE, I can select between the command window and the editor, but not see both at the same time.
Therefore I can't immediatly see outputs from print statements in my scripts.
Is there a layout that shows both or am I doing something else wrong?
You can drag any window and reposition it within the layout.
E.g., if you switch to the Editor window and click and drag with your mouse the editor's titlebar (i.e. the bit that says 'Editor', right about the editor's File / View menu), you can then start dragging it to the right, and identify a new 'grid' cell to drop it in.
If you're not getting an appropriate gridpoint to drop it in, try resetting the layout and trying again (from Window tab, select "Reset Default Window Layout" at the bottom)

paper-dialog: How to properly set backdrop overlay for stacked dialog

How do I set multiple backdrops for stacked paper dialogs?
Only the first dialog shows a backdrop. The second dialog doesn't show one
and I have set with-backdrop on both of them. How do I overlay the first dialog when the second dialog opens because I don't want the first dialog to be clickable when the second dialog opens?
Unfortunately not possible at the moment, but they seem to be working on it. See https://github.com/PolymerElements/iron-overlay-behavior/issues/124

Open a Vaadin `TabSheet` tab into a separate window

I want to give my users the option of opening a tab into its own window rather than merely switching the current window’s display to that tab. I have lots of tabs in my app, and the user often wants to study a few of those over long periods of time. For example, the user may watch charts being updated over time via Push.
Currently I add an "Open Window" button to a tab's layout. This opens a new browser window with the current tab’s layout.
Is there any other way to do this? A context-menu on the tab itself? User holding down a keyboard modifier (Control key, Command key, Option/Alt key) while clicking the tab?
Actually, there is one trick:
tabSheet.setCloseHandler((tabsheet, tabContent) -> {/** make new window **/});
Of course it works if tabSheet is closeable.
So if anybody click close button then you could do your own logic - in this example open new window.
But it could be misleading. To handle this problem you could replace close caption from x to any other more meaningful sign.
For example, look at Valo TabSheet demo. If you look in HTML code, than you notice something like this:
<span class="v-tabsheet-caption-close" aria-hidden="true" aria-disabled="true">×</span>
I think you are able to change this x using for example JavaScript.

window.location.reload refreshing the main window

the following is on a page, when i click it - I DO NOT want the page to refresh, but only the new window which this link opens - i want to refresh that newly opened page, not the main window.
clicking the link opens the new window correctly, but refreshes the main window also (where the link lies). that is undesirable and i want to know how to stop it from doing so.
clik to open new window
clik to open new window
pl advice.
as advised below, but not working: infact it is breaking the new window, new window appears as blank window!
clik to open new window
Here's the proper way to open a link in a new window. If javascript isn't available, the link will still work.
Click Me
mywin is a window name, not a variable.
You need to store the returned wobject from window.open() in a global variable:
onclick="window.mywin = window.open('URL','mywin');">
The problem with the main window reloading is likely the href="" line. This could be causing the browser to navigate to the same page where it is presently (and therefore refreshing). You should add return false; to the js, and likely also adopt a more standard link target like href="#" which will navigate to the top of the same page without a refresh (though this will still get cancelled by the false return).
friends, it is resolved by doing this:
clik to open new window

captureVisibleTab of non-visible tab

Is it possible to take a screenshot of non-visible tab with chrome extension API?
chrome.tabs.captureVisibleTab takes only the selected tab on a specific window.
I could programmatically switch to the needed tab, take a screenshot and switch back, but since it's all async, there's a flicker while it happens.
Copy the page to a new window and move the window outside the screen then take a screenshot. Then the user will not notice that you have opened a new window because it is outside the screen.
Hope this helps you out.