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

Problem with Full Screen Application #14

Open
dhpanteon opened this issue Mar 29, 2017 · 11 comments
Open

Problem with Full Screen Application #14

dhpanteon opened this issue Mar 29, 2017 · 11 comments

Comments

@dhpanteon
Copy link

When the application is in full screen mode (WindowState="Maximized", WindowStyle="None"). This library want work. it will first open the keyboard then automatically close it.

@maximcus
Copy link
Owner

@dhpanteon, what version of Windows are you using?

@dhpanteon
Copy link
Author

Windows 10 Enterprise 32-bit.

@maximcus
Copy link
Owner

Most likely your issue is more about Windows 10 (see #2) then full-screen. Does everything work ok if your app not in full-screen mode?

@dhpanteon
Copy link
Author

Yes it works but i need it in full screen mode. Even in my desktop full screen mode works fine.
But in tablet it's not working.

@maximcus
Copy link
Owner

Your desktop and tablet have different versions of Windows?

@dhpanteon
Copy link
Author

It's same.

@maximcus
Copy link
Owner

@dhpanteon, have you tried to find the problem in WPFTabTip source code and fix it yourself?

@dhpanteon
Copy link
Author

Yes have gone through your code. I have found the Problem that, it's conflict with in-build behavior of opening Tab Tip keyboard. i guess First it will open OS Behavior keyboard then it'll open WPFTab Tip keyboard. This is only happening with Tab or Mini Pos with no keyboard attach.

@dhpanteon
Copy link
Author

dhpanteon commented Mar 31, 2017

i have done some changes that solve my problem

public static void Open()
{
const string TabTipProcessName = "TabTip";
if (EnvironmentEx.GetOSVersion() == OSVersion.Win10)
EnableTabTipOpenInDesctopModeOnWin10();

        if (Process.GetProcessesByName(TabTipProcessName).Count() == 0)
        {
           
            Process.Start(TabTipExecPath);
        }
        else
        {
            try
            {//Close Previously opened keyboard
                if (Process.GetProcessesByName(TabTipProcessName).FirstOrDefault() != null)
                    Process.GetProcessesByName(TabTipProcessName).FirstOrDefault().Kill();
            }

            catch //(Access Error)  Sometime it gives Access Problem 
            { }
            Task.Yield(); // wait for it to close the keyboard

          Process.Start(TabTipExecPath);
        }

        //MessageBox.Show(value.HasValue ? value.Value.ToString() : "null");
        //MessageBox.Show(Process.GetProcessesByName(TabTipProcessName).Count().ToString());
    }


    public static void OpenUndocked()
    {
        const string TabTipDockedKey = "EdgeTargetDockedState";
        const string TabTipProcessName = "TabTip";

        int docked = (int)(Registry.GetValue(TabTipRegistryKeyName, TabTipDockedKey, 1) ?? 1);
        if (docked == 1)
        {
            Registry.SetValue(TabTipRegistryKeyName, TabTipDockedKey, 0);
            foreach (Process tabTipProcess in Process.GetProcessesByName(TabTipProcessName))
            {
                //(Access Error)  Sometime it gives Access Problem 
                try { tabTipProcess.Kill(); } catch { }
            }
        }
        Open();
    }

@leshric
Copy link

leshric commented Jul 28, 2017

I had the same issue and corrected it with the above code. Thanks!

@Cocotus
Copy link

Cocotus commented Aug 28, 2017

I had the same issues on Windows 10 tablet and this code solved it! Thanks!

Cocotus pushed a commit to Cocotus/WPFTabTipRevised that referenced this issue Feb 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants