Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Removing tab in full screen mode crashes app #14417

Open
phougt opened this issue Jan 10, 2024 · 4 comments
Open

Bug: Removing tab in full screen mode crashes app #14417

phougt opened this issue Jan 10, 2024 · 4 comments
Labels
bug Something isn't working 👀 crash Bug reports involving a crash

Comments

@phougt
Copy link

phougt commented Jan 10, 2024

Description

Greeting everyone,
Files crash whenever I close tab after creating it in fullscreen mode.
If I create a new tab in non-fullscreen mode, then delete it fullscreen mode, it doesn't crash.

Steps To Reproduce

  1. Open Files in fullscreen mode (F11)
  2. Add new tab.
  3. Close the newly created tab

Requirements

I expected it to not crash after closing tab.

Files Version

3.1.1.0

Windows Version

10.0.22635.2921

Log File

debug.log

@phougt phougt added the bug Something isn't working 👀 label Jan 10, 2024
@hishitetsu
Copy link
Member

I can reproduce this issue as well. But oddly enough, it doesn't reproduce when I enable debugging in Visual Studio.

@yaira2 yaira2 changed the title Files crash when removing tab in fullscreen mode Bug: Removing tab in full screen mode crashes app Jan 10, 2024
@yaira2
Copy link
Member

yaira2 commented Jan 10, 2024

Thank you for the report

@yaira2 yaira2 added the crash Bug reports involving a crash label Jan 10, 2024
@Qin-shihuang
Copy link
Contributor

It appears to be caused by PR #14342 .

@Qin-shihuang
Copy link
Contributor

This issue seems to no longer occur in version 3.5.0.0. But keep creating and closing new tabs in full-screen mode (create ~10 tabs, close them all, repeat) can sometimes cause crashes.

2024-07-06 14:44:55.2307|Error|System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
 ---> System.InvalidCastException: Specified cast is not valid.
   at WinRT.IObjectReference.As[T](Guid iid)
   at Microsoft.UI.Input.InputNonClientPointerSource..ctor(IObjectReference objRef)
   at InvokeStub_InputNonClientPointerSource..ctor(Object, Span`1)
   at System.Reflection.MethodBaseInvoker.InvokeWithOneArg(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   --- End of inner exception stack trace ---
   at System.Reflection.MethodBaseInvoker.InvokeWithOneArg(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at WinRT.DefaultComWrappers.CreateObject(IntPtr externalComObject)
   at System.Runtime.InteropServices.ComWrappers.CallCreateObject(ComWrappersScenario scenario, ComWrappers comWrappersImpl, IntPtr externalComObject, CreateObjectFlags flags)
   at System.Runtime.InteropServices.ComWrappers.<TryGetOrCreateObjectForComInstanceInternal>g____PInvoke|18_0(ObjectHandleOnStack __comWrappersImpl_native, Int64 __wrapperId_native, IntPtr __externalComObject_native, IntPtr __innerMaybe_native, CreateObjectFlags __flags_native, ObjectHandleOnStack __wrapper_native, ObjectHandleOnStack __retValue_native)
   at WinRT.ComWrappersSupport.CreateRcwForComObject[T](IntPtr ptr, Boolean tryUseCache)
   at WinRT.MarshalInspectable`1.FromAbi(IntPtr ptr)
   at ABI.Microsoft.UI.Input.IInputNonClientPointerSourceStaticsMethods.GetForWindowId(IObjectReference _obj, WindowId windowId)
   at Files.App.Helpers.DragZoneHelper.RaiseSetTitleBarDragRegion(Window window, SetTitleBarDragRegionDelegate setTitleBarDragRegion)
   at ABI.Microsoft.UI.Xaml.SizeChangedEventHandler.Do_Abi_Invoke(IntPtr thisPtr, IntPtr sender, IntPtr e)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working 👀 crash Bug reports involving a crash
Projects
Status: 🔖 Ready to build
Development

No branches or pull requests

4 participants