Ejemplo n.º 1
0
        public static void ShowFacebookLogin(string url, string urlFirst, Form parent)
        {
            if (instance != null)
            {
                try
                {
                    instance.Close();
                    instance = null;
                }
                catch (Exception)
                {
                }
            }
            vidLoaded = false;
            FacebookWindow window = new FacebookWindow();

            m_parent = null;
            Point point = new Point(parent.Location.X + ((parent.Width - window.Width) / 2), parent.Location.Y + ((parent.Height - window.Height) / 2));

            window.Location = point;
            window.Show(parent);
            instance = window;
            while (!vidLoaded)
            {
                Thread.Sleep(100);
                Application.DoEvents();
            }
            Thread.Sleep(500);
            if (urlFirst.Length > 0)
            {
                futureURL = url;
                url       = urlFirst;
            }
            window.webBrowser1.Navigate(url);
        }
Ejemplo n.º 2
0
 public static void ShowFacebookLogin(string url, string urlFirst, Form parent)
 {
     if (instance != null)
     {
         try
         {
             instance.Close();
             instance = null;
         }
         catch (Exception)
         {
         }
     }
     vidLoaded = false;
     FacebookWindow window = new FacebookWindow();
     m_parent = null;
     Point point = new Point(parent.Location.X + ((parent.Width - window.Width) / 2), parent.Location.Y + ((parent.Height - window.Height) / 2));
     window.Location = point;
     window.Show(parent);
     instance = window;
     while (!vidLoaded)
     {
         Thread.Sleep(100);
         Application.DoEvents();
     }
     Thread.Sleep(500);
     if (urlFirst.Length > 0)
     {
         futureURL = url;
         url = urlFirst;
     }
     window.webBrowser1.Navigate(url);
 }
Ejemplo n.º 3
0
 public static void closing()
 {
     if (m_parent != null)
     {
         m_parent.FacebookClose();
     }
     instance = null;
 }
Ejemplo n.º 4
0
 public static void closing()
 {
     if (m_parent != null)
     {
         m_parent.FacebookClose();
     }
     instance = null;
 }
Ejemplo n.º 5
0
 private void FacebookLogin(string userGuid)
 {
     if (m_parent != null)
     {
         m_parent.FacebookLogin(userGuid, "");
     }
     base.Close();
     instance = null;
 }
Ejemplo n.º 6
0
        public static void ShowFacebookLogin(string url, string urlFirst, ProfileLoginWindow parent, FacebookEventHandler loginCallback)
        {
            if (instance != null)
            {
                try
                {
                    instance.Close();
                    instance = null;
                }
                catch (Exception)
                {
                }
            }
            vidLoaded = false;
            FacebookWindow window = new FacebookWindow();

            m_parent = parent;
            Point point = new Point(parent.Location.X + ((parent.Width - window.Width) / 2), parent.Location.Y + ((parent.Height - window.Height) / 2));

            window.closeCallback = new MyFormBase.MFBClose(FacebookWindow.closing);
            window.Location      = point;
            window.Show(parent);
            instance = window;
            if (loginCallback != null)
            {
                instance.login = (FacebookEventHandler)Delegate.Combine(instance.login, loginCallback);
            }
            while (!vidLoaded)
            {
                Thread.Sleep(100);
                Application.DoEvents();
            }
            Thread.Sleep(500);
            if (urlFirst.Length > 0)
            {
                futureURL = url;
                url       = urlFirst;
            }
            window.webBrowser1.Navigate(url);
        }
Ejemplo n.º 7
0
 public static void ShowFacebookLogin(string url, string urlFirst, ProfileLoginWindow parent, FacebookEventHandler loginCallback)
 {
     if (instance != null)
     {
         try
         {
             instance.Close();
             instance = null;
         }
         catch (Exception)
         {
         }
     }
     vidLoaded = false;
     FacebookWindow window = new FacebookWindow();
     m_parent = parent;
     Point point = new Point(parent.Location.X + ((parent.Width - window.Width) / 2), parent.Location.Y + ((parent.Height - window.Height) / 2));
     window.closeCallback = new MyFormBase.MFBClose(FacebookWindow.closing);
     window.Location = point;
     window.Show(parent);
     instance = window;
     if (loginCallback != null)
     {
         instance.login = (FacebookEventHandler) Delegate.Combine(instance.login, loginCallback);
     }
     while (!vidLoaded)
     {
         Thread.Sleep(100);
         Application.DoEvents();
     }
     Thread.Sleep(500);
     if (urlFirst.Length > 0)
     {
         futureURL = url;
         url = urlFirst;
     }
     window.webBrowser1.Navigate(url);
 }
Ejemplo n.º 8
0
 private void FacebookLogin(string userGuid)
 {
     if (m_parent != null)
     {
         m_parent.FacebookLogin(userGuid, "");
     }
     base.Close();
     instance = null;
 }