Firefox - Using ITaskbarList::ActivateTab


  1. Posts : 122
    Windows 7 Ultimate x32
       #1

    Firefox - Using ITaskbarList::ActivateTab


    I use a toolbar button to toggle between normal and private windows.
    Here is the code:
    Code:
    OpenBrowserWindow({private: !PrivateBrowsingUtils.isWindowPrivate(window)});
    setTimeout(BrowserTryToCloseWindow, 80);
    I use 'setTimeout' in order to prevent some flickering.

    When the new window opens, it gets the focus.
    When the command 'BrowserTryToCloseWindow' is executed, the focus returns to the old window.
    When the old window is closed, the new one does have the focus, but it isn't 'checked / active' in Windows Task Bar.

    I suppose I need to use ITaskbarList::ActivateTab in order to activate the new window in the task bar.
    I have the (very) basic direction:
    Code:
    Components.utils.import("resource://gre/modules/ctypes.jsm");
    var lib = ctypes.open("shell32.dll");
    var taskBar = lib.declare(---
    taskBar---
    lib.close();
    I'd appreciate your help.

    Win 7, 32-bit, Classic Theme.

    Posted here too.
    Last edited by Yaron; 07 Dec 2014 at 20:44.
      My Computer


  2. Posts : 1,810
    Dual Boot: Windows 8.1 & Server 2012r2 VMs: Kali Linux, Backbox, Matriux, Windows 8.1
       #2

    You may find someone who knows this answer here, but its more likely to find help on a Firefox developers forum or a place like Stack Overflow
      My Computer


  3. Posts : 122
    Windows 7 Ultimate x32
    Thread Starter
       #3
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 22:45.
Find Us