Ejemplo n.º 1
0
 public ClickCountForm()
 {
     InitializeComponent();
     ClickCount.ShowBalloonTip(2000, "Atention", "APP Enabled!", ToolTipIcon.Info);
     MouseHook.Start();
     MouseHook.MouseAction += new EventHandler(Event);
 }
Ejemplo n.º 2
0
 //构造函数
 public AutoClickMouseLeftButton()
 {
     InitializeComponent();
     System.Windows.Forms.Control.CheckForIllegalCrossThreadCalls = false;
     LB_Numbers.Text = ClickCount.ToString();
     //调用初始化托盘显示函数
     InitialTray();
     RegisterHotKey(this.Handle, 10, MODKEY.None, Keys.F9);
     RegisterHotKey(this.Handle, 11, MODKEY.None, Keys.F10);
 }
Ejemplo n.º 3
0
    void OnMouseDown()
    {
        ClickCount.Instantiate(this.clickCount);
        this.clickCount.Value++;
        //ClickCount someInstance = ScriptableObject.CreateInstance("ClickCount") as ClickCount;
        this.clickCount = Resources.Load<ClickCount>("ClickCount");

        this.clickCount.Colour = new Color (1.0f * (float)Random.Range (0.1f, 0.9f), 1.0f * (float)Random.Range (0.1f, 0.9f), 1.0f * (float)Random.Range (0.1f, 0.9f));

        GetComponent<Renderer>().sharedMaterial.SetColor ("_Color", clickCount.Colour);
    }
Ejemplo n.º 4
0
        //Tetiana lagrer i db antall klikk på kategorier
        public bool SaveClickCount(ClickCountDTO clickIn)
        {
            try
            {
                var clickedOn = new ClickCount
                {
                    Username    = clickIn.Username,
                    CategoryId  = clickIn.CategoryId,
                    DateClicked = clickIn.ClickDate,
                    IsMainCat   = clickIn.IsMainCat
                };
                _dbContext.ClickCount.Add(clickedOn);
                _dbContext.SaveChanges();
                return(true);
            }

            catch (Exception)
            {
                return(false);
            }
        }
Ejemplo n.º 5
0
 void Start()
 {
     clickCount = Resources.Load<ClickCount>("ClickCount");
 }
Ejemplo n.º 6
0
 private void ClickCount_Click(object sender, EventArgs e)
 {
     ClickCount.Visible = true;
     ClickCount.ShowBalloonTip(20000, "Total Clicks", clicks.ToString(), ToolTipIcon.Info);
 }