Magellan Linux

Contents of /mcore-src/trunk/mcore-tools/src/modules/basic-video/graphic.control.class.in

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2640 - (show annotations) (download)
Fri Oct 2 09:24:51 2015 UTC (8 years, 6 months ago) by niro
File size: 2637 byte(s)
-fixed a typo
1 # $Id$
2
3 push_config 10_graphic_resolution
4 push_config 10_graphic_depth
5 push_config 10_graphic_module
6
7 help_graphic_resolution()
8 {
9 local serial="${CLASS_ARGV[0]}"
10 control_client "${serial}" help graphic.resolution
11 }
12
13 help_graphic_refresh()
14 {
15 local serial="${CLASS_ARGV[0]}"
16 control_client "${serial}" help graphic.refresh
17 }
18
19 help_graphic_depth()
20 {
21 local serial="${CLASS_ARGV[0]}"
22 control_client "${serial}" help graphic.depth
23 }
24
25 help_graphic_driver()
26 {
27 local serial="${CLASS_ARGV[0]}"
28 control_client "${serial}" help graphic.driver
29 }
30
31 # set_graphic_driver $serial $value
32 set_graphic_driver()
33 {
34 local serial="${CLASS_ARGV[0]}"
35 local value="${CLASS_ARGV[1]}"
36
37 import_resource cfg_graphic "${serial}" module "${value}"
38 }
39
40 control_graphic_driver()
41 {
42 local serial="${CLASS_ARGV[0]}"
43 push_config_10_graphic_driver "${serial}"
44 }
45
46 push_config_10_graphic_driver()
47 {
48 local serial="$1"
49 local value
50
51 value=$(mysqldo "select module from cfg_graphic where serial='${serial}'")
52 control_client "${serial}" set graphic.driver "${value}"
53 }
54
55 # set_graphic_resolution $serial $value
56 set_graphic_resolution()
57 {
58 local serial="${CLASS_ARGV[0]}"
59 local value="${CLASS_ARGV[1]}"
60
61 import_resource cfg_graphic "${serial}" resolution "${value}"
62 }
63
64 # control_graphic_resolution $serial
65 control_graphic_resolution()
66 {
67 local serial="${CLASS_ARGV[0]}"
68 push_config_10_graphic_resolution "${serial}"
69 }
70
71 push_config_10_graphic_resolution()
72 {
73 local serial="$1"
74 local value
75
76 value=$(mysqldo "select resolution from cfg_graphic where serial='${serial}'")
77 control_client "${serial}" set graphic.resolution "${value}"
78 }
79
80 # set_graphic_depth $serial $value
81 set_graphic_depth()
82 {
83 local serial="${CLASS_ARGV[0]}"
84 local value="${CLASS_ARGV[1]}"
85
86 import_resource cfg_graphic "${serial}" depth "${value}"
87 }
88
89 control_graphic_depth()
90 {
91 local serial="${CLASS_ARGV[0]}"
92 push_config_10_graphic_depth "${serial}"
93 }
94
95 push_config_10_graphic_depth()
96 {
97 local serial="$1"
98 local value
99
100 value=$(mysqldo "select depth from cfg_graphic where serial='${serial}'")
101 control_client "${serial}" set graphic.depth "${value}"
102 }
103
104 # set_graphic_refesh $serial $value
105 set_graphic_refresh()
106 {
107 local serial="${CLASS_ARGV[0]}"
108 local value="${CLASS_ARGV[1]}"
109
110 import_resource cfg_graphic "${serial}" refresh_rate "${value}"
111 }
112
113 # control_graphic_resolution $serial
114 control_graphic_refresh()
115 {
116 local serial="${CLASS_ARGV[0]}"
117 push_config_10_graphic_refresh "${serial}"
118 }
119
120 push_config_10_graphic_refresh()
121 {
122 local serial="$1"
123 local value
124
125 value=$(mysqldo "select hz from cfg_graphic where serial='${serial}'")
126 control_client "${serial}" set graphic.resolution "${value}"
127 }