Exemplo n.º 1
0
        public SharkIt()
        {
            InitializeComponent();
            WindowState = FormWindowState.Minimized;
            m_path = Properties.Settings.Default.Path;
            ShowInTaskbar = false;
            // Ignore about localization for now
            systemTray.Text = "Connecting...";
            //systemTray.Icon = Resources.download_red;
            systemTray.BalloonTipClicked += new EventHandler(systemTray_BalloonTipClicked);

            m_session = new Session();
            m_api = new API(m_session);
            m_session.GotSID += new Session.GotSIDHandler(m_gs_GotSID);
            m_session.GotToken += new Session.GotTokenHandler(m_gs_GotToken);

            Timer t = new Timer();
            t.Interval = 50;
            t.Tick += new EventHandler(ClipboardWatcher);
            t.Start();
        }
Exemplo n.º 2
0
 public API(Session session)
 {
     m_session = session;
     m_session.GotToken += new Session.GotTokenHandler(m_session_GotToken);
 }
Exemplo n.º 3
0
 public void getCommunicationTokenHandler(Session gs, JObject response, object state)
 {
     string token = (string)response["result"];
     m_token = token;
     GotToken(this, token);
 }