Bug fix
parent
6c1c483496
commit
ade994dac8
|
@ -275,91 +275,91 @@ func (c *Cli) DrawCLear() error {
|
|||
}
|
||||
|
||||
func (c *Cli) DrawBox(x, y, w, h, t int) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/draw/addbox?x=%d&y=%d&w=%d&h=%d&t=%d", x, y, w, h, t), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/draw/addbox?x=%d&y=%d&w=%d&h=%d&t=%d", x, y, w, h, t), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) DrawRect(x, y, w, h int) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/draw/addrect?x=%d&y=%d&w=%d&h=%d", x, y, w, h), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/draw/addrect?x=%d&y=%d&w=%d&h=%d", x, y, w, h), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) DrawAddText(t string, x, y, w, h int) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/draw/addtext?t=%s&x=%d&y=%d&w=%d&h=%d", t, x, y, w, h), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/draw/addtext?t=%s&x=%d&y=%d&w=%d&h=%d", t, x, y, w, h), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
/***************** Notify Functions *****************/
|
||||
|
||||
func (c *Cli) NotifyAlert(msg, title string) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/notify/alert?msg=%s&title=%s", msg, title), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/notify/alert?msg=%s&title=%s", msg, title), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) NotifyBeep(msg, title string) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/notify/notify?msg=%s&title=%s", msg, title), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/notify/notify?msg=%s&title=%s", msg, title), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
/***************** Window Functions *****************/
|
||||
|
||||
func (c *Cli) WindowList(s string) (ret []map[string]interface{}, err error) {
|
||||
err = c.HttpCli().JsonGet("/ipc/window/list?s="+s, &ret)
|
||||
err = c.HttpCli().JsonGet("/ipc/wingui/window/list?s="+s, &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowHwnd(s string) (ret []int, err error) {
|
||||
err = c.HttpCli().JsonGet("/ipc/window/hwnd?s="+s, &ret)
|
||||
err = c.HttpCli().JsonGet("/ipc/wingui/window/hwnd?s="+s, &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowActivate(Hwnd string) error {
|
||||
err := c.HttpCli().JsonGet("/ipc/window/activate?Hwnd="+Hwnd, nil)
|
||||
err := c.HttpCli().JsonGet("/ipc/wingui/window/activate?Hwnd="+Hwnd, nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowClose(Hwnd string) error {
|
||||
err := c.HttpCli().JsonGet("/ipc/window/close?Hwnd="+Hwnd, nil)
|
||||
err := c.HttpCli().JsonGet("/ipc/wingui/window/close?Hwnd="+Hwnd, nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowMax(Hwnd string) error {
|
||||
err := c.HttpCli().JsonGet("/ipc/window/max?Hwnd="+Hwnd, nil)
|
||||
err := c.HttpCli().JsonGet("/ipc/wingui/window/max?Hwnd="+Hwnd, nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowMin(Hwnd string) error {
|
||||
err := c.HttpCli().JsonGet("/ipc/window/min?Hwnd="+Hwnd, nil)
|
||||
err := c.HttpCli().JsonGet("/ipc/wingui/window/min?Hwnd="+Hwnd, nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowActiveHwnd() (ret int, err error) {
|
||||
err = c.HttpCli().JsonGet("/ipc/window/activehwnd", &ret)
|
||||
err = c.HttpCli().JsonGet("/ipc/wingui/window/activehwnd", &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowWaitActiveTitle(t string, m int) (ret map[string]interface{}, err error) {
|
||||
err = c.HttpCli().JsonGet(fmt.Sprintf("/ipc/window/waitactivetitle?t=%s&m=%d", t, m), &ret)
|
||||
err = c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/window/waitactivetitle?t=%s&m=%d", t, m), &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowActiveTitle() (ret string, err error) {
|
||||
err = c.HttpCli().JsonGet("/ipc/window/activetitle", &ret)
|
||||
err = c.HttpCli().JsonGet("/ipc/wingui/window/activetitle", &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
/*func (c *Cli) WindowWinfo(w int) (ret interface{}, err error) {
|
||||
err = c.HttpCli().JsonGet(fmt.Sprintf("/ipc/window/winfo?w=%d", w), &ret)
|
||||
err = c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/window/winfo?w=%d", w), &ret)
|
||||
return ret, err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowSendMsg(w, m string) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/window/sendmsg?w=%s&m=%s", w, m), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/window/sendmsg?w=%s&m=%s", w, m), nil)
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Cli) WindowPostMsg(w, m string) error {
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/window/postmsg?w=%s&m=%s", w, m), nil)
|
||||
err := c.HttpCli().JsonGet(fmt.Sprintf("/ipc/wingui/window/postmsg?w=%s&m=%s", w, m), nil)
|
||||
return err
|
||||
}*/
|
||||
|
||||
|
|
Loading…
Reference in New Issue