Menu

possible bug in windows version (doesn't return focus properly)

2015-02-23
2015-03-28
  • dion starfire

    dion starfire - 2015-02-23

    I'd file a bug report for this myself, but I'm not a programmer, and I'm not certain this isn't due to something I've done. I don't want to clutter the bug list with an incomplete report.

    In Windows 7, when I close notepad++ it does NOT switch focus to the last active window.

    For example, if I'm browsing a folder full of text files and I open one in Microsoft's notepad (the one that's built into Windows) then close notepad, focus shifts back to the explorer window I opened the text file from.

    If I open the same file (from the same folder) in notepad++ then close it, focus does not return to the last active window (i.e. I can't use the keyboard to select a different file, search for one, activate the menu bar, etc.). However, a single alt-tab will take me to the window that had focus prior to the explorer window, just as if that explorer window (the one I opened the text file/launched notepad++ from) were the current active window.

    I'm using notepad++ 6.1.4, on Windows 7 x64 Professional. I've tweaked a variety of windows settings, though I don't recall any that should cause this behavior.

    I have the following plugins installed:
    Autosave2 1.0
    Compate 1.5.6
    Customize Toolbar 3.8
    Location Navigate 0.4.7.7
    MIME Tools 1.9
    NewFileBrowser 0.1.3
    NPPExport 0.2.8
    NPPJumpList 1.2.2
    Plugin Manager 1.3.5
    Save as admin 1.0.0.3
    Spell Checker 1.3.3
    TextFX Character 0.2.6

    This is the biggest annoyance I've encountered so far with notepad++, and it's pretty minor, all things considered, especially when you compare it to the bugs you can find in many other programs (including most commercial ones). So, the devs are definitely doing a d*mn fine job.

     
  • Lei Hu

    Lei Hu - 2015-03-25

    I've got exactly the same problem. I've used NP++ for a long time and many different versions. I really love this program! However, this focus issue is really annoying. Hope it can be fixed in the next version. Thanks.

     
  • Andreas Jonsson

    Andreas Jonsson - 2015-03-26

    The first step is to rule out that this is caused by a plugin. Rename the plugin directory (Program Files (x86)\Notepad++\plugins) to something else temporarily and see if the problem still occurs.

     
    • dion starfire

      dion starfire - 2015-03-27

      Thanks, Andreas. Renaming the user-specific plugins folder fixed the problem.

      Next step is to determine which specific plugin is causing the problem.

      I'll report back when I find it.

       

      Last edit: dion starfire 2015-03-27
  • dion starfire

    dion starfire - 2015-03-27

    Okay, after a bit of testing, I've found that removing the compare plugin eliminated the problem (for now).

    It seems weird that a simple plugin (especially that one) could cause Notepad++ to misbehave in this way. However, I'm not exactly a programmer (I'm on the user support/admin side of tech).

     
    • Andreas Jonsson

      Andreas Jonsson - 2015-03-28

      Well, a plugin is just a program and can do everything any other program can do. I'm guessing that the Compare plugin does not release some resource back to Windows which causes it to think that the N++ window is still open.