I have a set of jquery-ui tabs, the content of which is loaded via ajax. I would like to be able to force (somehow) the active option to work even if the tab is currently active (for refresh purposes).
Doing something like this: $('#'+tab_group_id).tabs('option', 'active', tab.index());
After reading this thread, it looks like if the tab is already active, trying to activate it does nothing. How can I achieved the desired behavior of "forcing" an activate?
Related
Why doesn't rails turbo-stream-from update the dom when we're not in the application tab in the browser?
When we go back to the tab in the browser where the application is, all items are inserted at once at this point.
I don't know the logic exactly
but I think there are 2 possibilities:
it uses Browser Window focus event, so the update will be done when the user has opened the tab
it's a limitation from the browser, to prevent unnecessary CPU usage, it doesn't want to update the content if user is focusing on another tab
I am trying to identify if a TCommonDialog (Open, Save etc) is active in my application but they do not appear to trigger OnModalBegin or change the Application.ModalLevel despite clearly having modal status.
I am intercepting keyboard events in my application and I want to pass through these keybaord events under some conditions. One of the conditions to do the pass through is a dialog box being open but I cant find a way to detect this.
Is there a way to know when a decedent of TCommonDialog is active?
I made my GUI using Qt Designer and I have a QTabWidget with multiple tabs. My tabs contain specific tools that are used in my app. Now I would like to set my tabs closable and movable so I could save the order of my tabs and load it when the app starts. The problem is, I don't know how to reorder my tabs when the application loads. Is this possible?
You can move tabs by accessing the QTabBar object associated with the QTabQidget
QTabBar has a method moveTab() which will allow you to reorder tabs.
So you would do something like my_tab_widget.tabBar().moveTab(old_position, new_position) where old_position and new_position are integers which specify the tab to move and the position to move it to respectively.
Lots of details in the c++ documentation (it translates to python pretty easily). See QTabBar docs and QTabWidget docs
I have an application that uses jQuery tabs to display different dynamic content for the user. The user has the ability to subscribe to various information feeds into "pods" on each tab. So for example the first tab might have 4 pods and each pod on the tab displays different information. The user has the ability to select a different template for each tab (like 4 smaller pods, or 2 larger ones, etc).
I have built a user interface to allow the user to rename the tab and to change the template that is displayed in that tab. The problem is when the user changes the template for a tab, the tab does not refresh/reload to show the new template. The only way to display the new template is to reload the whole screen.
I have tried using the following code after the tab has been updated in the database
$("#tabselector").tabs("load", tabindex);
However the above does not seem to reload the tab. I am not sure what I am doing wrong. Any suggestions would be greatly appreciated.
I'm not sure I got your question, but I'll try to guess what you are after from the last paragraph of your question.
If you want to change the URL of the remote/AJAX tab, you need to use the .tabs( "url" , index , url ) method. The load method will not load the tab again if it is already loaded. See the documentation.
I would like to implement a "Module Switcher" in my application, which brings up an alt-tab like interface showing the open modules.
Right now it is structured like this
ModuleShellView
ModuleSwitcherView
Module 1 Module 2 Module 3
ModuleSwitcherView is opened as a dialog from ModuleShellView and binds to the currently open Modules.
This causes the active module in the screen behind to transition to nothing. Is there a way to keep the view open in the background, while displaying it in another dialog? The alt-tab window only needs a "view" of the view, it doesn't need to be interactive.
I have found a workaround for this. Rather than show the contentcontrol, I am grabbing the view instance, writing it to a WriteableBitmap and then using that.