danjulio / tCam

Thermal imaging cameras based on the ESP32 and Lepton 3.5
GNU General Public License v3.0
103 stars 25 forks source link

Windows app continues to run on the background when closed #14

Open CVasilakis opened 2 months ago

CVasilakis commented 2 months ago

I noticed the issue when i tried to move the folder which contains the tCam windows app. An error appeared saying that i can't move the folder because the app was still running. Although i had closed the app. Then i opened the task manager to check the running apps. There i saw that each time i opened the tCam app a new task was spawned, which did not clear after closing the app. Below i attach a sceenshot from the task manager: Screenshot 2024-08-15 150726 As you can see there are 3 background processes for the tCam (each of which consume considerable amount of RAM - even closed). This is exactly the number that i had opened and closed the tCam app (3 times). Please note that the tCam app was closed all this times (not minimized) and that there is no instance of the app in the taskbar tray.

danjulio commented 2 months ago

Oh shoot. I think I know what’s going on. Did you close the app using the window close decoration or from the pull-down menu to quit it? If you closed it from the window itself then I think I must not be catching that as a reason to exit it.

On Aug 15, 2024, at 6:18 AM, Christoforos Vasilakis @.***> wrote:

I noticed the issue when i tried to move the folder which contains the tCam windows app. An error appeared saying that i can't move the folder because the app was still running. Although i had closed the app. Then i opened the task manager to check the running apps. There i saw that each time i opened the tCam app a new task was spawned, which did not clear after closing the app. Below i attach a sceenshot from the task manager: Screenshot.2024-08-15.150726.png (view on web) https://github.com/user-attachments/assets/bdcdfcbc-9633-44ae-b54c-496919cc5c8a As you can see there are 3 background processes for the tCam (each of which consume considerable amount of RAM - even closed). This is exactly the number that i had opened and closed the tCam app (3 times). Please note that the tCam app was closed all this times (not minimized) and that there is no instance of the app in the taskbar tray.

— Reply to this email directly, view it on GitHub https://github.com/danjulio/tCam/issues/14, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABOB66S6JSNGSI42LWSOU4LZRSMARAVCNFSM6AAAAABMSDEJ6OVHI2DSMVQWIX3LMV43ASLTON2WKOZSGQ3DOOJUGE3DQNI. You are receiving this because you are subscribed to this thread.

CVasilakis commented 2 months ago

Oh shoot. I think I know what’s going on. Did you close the app using the window close decoration or from the pull-down menu to quit it? If you closed it from the window itself then I think I must not be catching that as a reason to exit it.

You are right. I closed the program using the window close decoration. I just tested what you wrote. I confirm that if i use the "exit" button from the pull-down menu, then there is no such problem. Though, i think that both actions (closing from the decoration or the pull-down manu) should have the same behavior, otherwise the user should be questioned whether he wants the app to run on the background when the "X" decoration button is pressed.