mirror of
https://github.com/clockworkpi/LauncherGoDev.git
synced 2026-03-21 11:22:37 +01:00
continue wifi_list
This commit is contained in:
51
sysgo/UI/info_page_selector.go
Normal file
51
sysgo/UI/info_page_selector.go
Normal file
@@ -0,0 +1,51 @@
|
||||
package UI
|
||||
|
||||
import (
|
||||
// "github.com/veandco/go-sdl2/ttf"
|
||||
|
||||
// "github.com/cuu/gogame/surface"
|
||||
// "github.com/cuu/gogame/event"
|
||||
"github.com/cuu/gogame/rect"
|
||||
"github.com/cuu/gogame/color"
|
||||
"github.com/cuu/gogame/draw"
|
||||
|
||||
)
|
||||
|
||||
type InfoPageSelector struct {
|
||||
PageSelector
|
||||
BackgroundColor *color.Color
|
||||
}
|
||||
|
||||
func NewInfoPageSelector() *InfoPageSelector {
|
||||
p := &InfoPageSelector{}
|
||||
|
||||
p.Width = Width
|
||||
p.BackgroundColor = &color.Color{131,199,219,255} //SkinManager().GiveColor('Front')
|
||||
|
||||
return p
|
||||
|
||||
}
|
||||
|
||||
func (self *InfoPageSelector) AnimateDraw(x2, y2 int) {
|
||||
//pass
|
||||
}
|
||||
|
||||
func (self *InfoPageSelector) Draw() {
|
||||
idx := self.Parent.GetPsIndex()
|
||||
mylist := self.Parent.GetMyList()
|
||||
|
||||
if idx < len(mylist) {
|
||||
x,y := mylist[idx].Coord()
|
||||
w,h := mylist[idx].Size()
|
||||
|
||||
self.PosY = y+1
|
||||
self.Height = h-3
|
||||
|
||||
canvas_ := self.Parent.GetCanvasHWND()
|
||||
rect_ := rect.Rect(self.PosX,self.PosY,self.Width-4, self.Height)
|
||||
|
||||
draw.AARoundRect(canvas_,&rect_,self.BackgroundColor,4,0,self.BackgroundColor)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user