/[aagtl_public1]/src/com/zoffcc/applications/aagtl/CrossHair.java
aagtl

Diff of /src/com/zoffcc/applications/aagtl/CrossHair.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 3 Revision 4
28import android.graphics.RectF; 28import android.graphics.RectF;
29import android.widget.ImageView; 29import android.widget.ImageView;
30 30
31public class CrossHair extends ImageView 31public class CrossHair extends ImageView
32{ 32{
33 int middle_size = 10; 33 int middle_size = 10;
34 double gps_acc = -1; 34 double gps_acc = -1;
35 double gps_heading = -1; 35 double gps_heading = -1;
36 int used_sats = 0; 36 int used_sats = 0;
37 Path menu_text_path = new Path();
38 Paint paint_gps = new Paint(0);
37 39
38 aagtl main_aagtl; 40 aagtl main_aagtl;
39 41
40 public CrossHair(Context context, aagtl main) 42 public CrossHair(Context context, aagtl main)
41 { 43 {
42 super(context); 44 super(context);
43 this.main_aagtl = main; 45 this.main_aagtl = main;
76 //System.out.println("CrossHair: onDraw"); 78 //System.out.println("CrossHair: onDraw");
77 79
78 Paint paint = new Paint(0); 80 Paint paint = new Paint(0);
79 paint.setAntiAlias(false); 81 paint.setAntiAlias(false);
80 paint.setColor(Color.GRAY); 82 paint.setColor(Color.GRAY);
81 c.drawLine(this.getWidth() / 2, 0, this.getWidth() / 2, this.getHeight() / 2 - middle_size, 83 c.drawLine(this.getWidth() / 2, 0, this.getWidth() / 2, this.getHeight() / 2 - middle_size, paint);
82 paint);
83 c.drawLine(this.getWidth() / 2, this.getHeight() / 2 + middle_size, this.getWidth() / 2, this 84 c.drawLine(this.getWidth() / 2, this.getHeight() / 2 + middle_size, this.getWidth() / 2, this.getHeight(), paint);
84 .getHeight(), paint);
85 85
86 c.drawLine(0, this.getHeight() / 2, this.getWidth() / 2 - middle_size, this.getHeight() / 2, 86 c.drawLine(0, this.getHeight() / 2, this.getWidth() / 2 - middle_size, this.getHeight() / 2, paint);
87 paint);
88 c.drawLine(this.getWidth() / 2 + middle_size, this.getHeight() / 2, this.getWidth(), this 87 c.drawLine(this.getWidth() / 2 + middle_size, this.getHeight() / 2, this.getWidth(), this.getHeight() / 2, paint);
89 .getHeight() / 2, paint);
90
91 88
92 // -- SUN -- 89 // -- SUN --
93 // -- SUN -- 90 // -- SUN --
94 // -- SUN -- 91 // -- SUN --
95 // set correct sun values 92 // set correct sun values
103 // moon not visible 100 // moon not visible
104 } 101 }
105 else 102 else
106 { 103 {
107 // moon is visible!! 104 // moon is visible!!
108 double x1 = this.getWidth() / 2 105 double x1 = this.getWidth() / 2 + Math.sin(Math.toRadians(this.main_aagtl.arrowview.moon_azimuth_cache)) * (this.getWidth() / 2) * 0.9;
109 + Math.sin(Math.toRadians(this.main_aagtl.arrowview.moon_azimuth_cache)) 106 double y1 = this.getHeight() / 2 - Math.cos(Math.toRadians(this.main_aagtl.arrowview.moon_azimuth_cache)) * (this.getHeight() / 2) * 0.9;
110 * (this.getWidth() / 2) * 0.9;
111 double y1 = this.getHeight() / 2
112 - Math.cos(Math.toRadians(this.main_aagtl.arrowview.moon_azimuth_cache))
113 * (this.getHeight() / 2) * 0.9;
114 107
115 int radius_x = 6; 108 int radius_x = 6;
116 int radius_y = 6; 109 int radius_y = 6;
117 RectF sun_oval = null; 110 RectF sun_oval = null;
118 // day 111 // day
119 112
120 // draw yellow sun 113 // draw yellow sun
121 Paint paint_gps = new Paint(0); 114 paint_gps.reset();
122 paint_gps.setColor(Color.parseColor("#EBEBEB")); 115 paint_gps.setColor(Color.parseColor("#EBEBEB"));
123 paint_gps.setStyle(Paint.Style.FILL); 116 paint_gps.setStyle(Paint.Style.FILL);
124 paint_gps.setAntiAlias(true); 117 paint_gps.setAntiAlias(true);
125 radius_x = 6; 118 radius_x = 6;
126 radius_y = 6; 119 radius_y = 6;
127 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), 120 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), (int) (y1 + radius_y));
128 (int) (y1 + radius_y));
129 c.drawArc(sun_oval, 0, 360, false, paint_gps); 121 c.drawArc(sun_oval, 0, 360, false, paint_gps);
130 // 122 //
131 // draw black circle 123 // draw black circle
132 paint_gps.setColor(Color.parseColor("#000000")); 124 paint_gps.setColor(Color.parseColor("#000000"));
133 paint_gps.setStyle(Paint.Style.STROKE); 125 paint_gps.setStyle(Paint.Style.STROKE);
134 paint_gps.setAntiAlias(true); 126 paint_gps.setAntiAlias(true);
135 paint_gps.setStrokeWidth(1); 127 paint_gps.setStrokeWidth(1);
136 radius_x = 6; 128 radius_x = 6;
137 radius_y = 6; 129 radius_y = 6;
138 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), 130 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), (int) (y1 + radius_y));
139 (int) (y1 + radius_y));
140 c.drawArc(sun_oval, 0, 360, false, paint_gps); 131 c.drawArc(sun_oval, 0, 360, false, paint_gps);
141 132
142 } 133 }
143 134
144 if (this.main_aagtl.arrowview.elevation < -0.83) 135 if (this.main_aagtl.arrowview.elevation < -0.83)
145 { 136 {
146 // night 137 // night
147 } 138 }
148 else 139 else
149 { 140 {
150 double x1 = this.getWidth() / 2 141 double x1 = this.getWidth() / 2 + Math.sin(Math.toRadians(this.main_aagtl.arrowview.azmiuth_cache)) * (this.getWidth() / 2) * 0.9;
151 + Math.sin(Math.toRadians(this.main_aagtl.arrowview.azmiuth_cache)) 142 double y1 = this.getHeight() / 2 - Math.cos(Math.toRadians(this.main_aagtl.arrowview.azmiuth_cache)) * (this.getHeight() / 2) * 0.9;
152 * (this.getWidth() / 2) * 0.9;
153 double y1 = this.getHeight() / 2
154 - Math.cos(Math.toRadians(this.main_aagtl.arrowview.azmiuth_cache))
155 * (this.getHeight() / 2) * 0.9;
156 143
157 int radius_x = 6; 144 int radius_x = 6;
158 int radius_y = 6; 145 int radius_y = 6;
159 RectF sun_oval = null; 146 RectF sun_oval = null;
160 // day 147 // day
161 148
162 // draw yellow sun 149 // draw yellow sun
163 Paint paint_gps = new Paint(0); 150 paint_gps.reset();
164 paint_gps.setColor(Color.parseColor("#FFFF66")); 151 paint_gps.setColor(Color.parseColor("#FFFF66"));
165 paint_gps.setStyle(Paint.Style.FILL); 152 paint_gps.setStyle(Paint.Style.FILL);
166 paint_gps.setAntiAlias(true); 153 paint_gps.setAntiAlias(true);
167 radius_x = 6; 154 radius_x = 6;
168 radius_y = 6; 155 radius_y = 6;
169 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), 156 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), (int) (y1 + radius_y));
170 (int) (y1 + radius_y));
171 c.drawArc(sun_oval, 0, 360, false, paint_gps); 157 c.drawArc(sun_oval, 0, 360, false, paint_gps);
172 // 158 //
173 // draw black circle 159 // draw black circle
174 paint_gps.setColor(Color.parseColor("#000000")); 160 paint_gps.setColor(Color.parseColor("#000000"));
175 paint_gps.setStyle(Paint.Style.STROKE); 161 paint_gps.setStyle(Paint.Style.STROKE);
176 paint_gps.setAntiAlias(true); 162 paint_gps.setAntiAlias(true);
177 paint_gps.setStrokeWidth(1); 163 paint_gps.setStrokeWidth(1);
178 radius_x = 6; 164 radius_x = 6;
179 radius_y = 6; 165 radius_y = 6;
180 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), 166 sun_oval = new RectF((int) (x1 - radius_x), (int) (y1 - radius_y), (int) (x1 + radius_x), (int) (y1 + radius_y));
181 (int) (y1 + radius_y));
182 c.drawArc(sun_oval, 0, 360, false, paint_gps); 167 c.drawArc(sun_oval, 0, 360, false, paint_gps);
183 } 168 }
184 169
185 // -- SUN -- 170 // -- SUN --
186 // -- SUN -- 171 // -- SUN --
187 // -- SUN -- 172 // -- SUN --
188
189 173
190 if (this.main_aagtl.isGPSFix) 174 if (this.main_aagtl.isGPSFix)
191 { 175 {
192 if (!this.main_aagtl.global_settings.options_turn_map_on_heading) 176 if (!this.main_aagtl.global_settings.options_turn_map_on_heading)
193 { 177 {
194 // have gps fix 178 // have gps fix
195 if (this.gps_acc != -1) 179 if (this.gps_acc != -1)
196 { 180 {
197 Paint paint_gps = new Paint(0); 181 paint_gps.reset();
198 paint_gps.setColor(Color.parseColor("#0000AA")); 182 paint_gps.setColor(Color.parseColor("#0000AA"));
199 paint_gps.setStyle(Paint.Style.STROKE); 183 paint_gps.setStyle(Paint.Style.STROKE);
200 paint_gps.setAntiAlias(true); 184 paint_gps.setAntiAlias(true);
201 185
202 // calc gps_acc (in meters) into pixels (in current zoomlevel) 186 // calc gps_acc (in meters) into pixels (in current zoomlevel)
212 //System.out.println("acc radius y=" + radius_y); 196 //System.out.println("acc radius y=" + radius_y);
213 //System.out.println("zoom=" + this.main_aagtl.rose.zoom); 197 //System.out.println("zoom=" + this.main_aagtl.rose.zoom);
214 //System.out.println("gps acc=" + gps_acc); 198 //System.out.println("gps acc=" + gps_acc);
215 //System.out.println("n=" + n); 199 //System.out.println("n=" + n);
216 200
217 201 RectF gps_oval = new RectF(this.getWidth() / 2 - (int) radius_x, this.getHeight() / 2 - (int) radius_y, this.getWidth() / 2 + (int) radius_x, this.getHeight() / 2 + (int) radius_y);
218 RectF gps_oval = new RectF(this.getWidth() / 2 - (int) radius_x, this.getHeight()
219 / 2 - (int) radius_y, this.getWidth() / 2 + (int) radius_x, this.getHeight()
220 / 2 + (int) radius_y);
221 c.drawArc(gps_oval, 0, 360, false, paint_gps); 202 c.drawArc(gps_oval, 0, 360, false, paint_gps);
222
223 203
224 // show the heading on map 204 // show the heading on map
225 //System.out.println("-> heading=" + this.gps_heading); 205 //System.out.println("-> heading=" + this.gps_heading);
226 int size = 16; 206 int size = 16;
227 double s1 = Math.sin(Math.toRadians(this.gps_heading)); 207 double s1 = Math.sin(Math.toRadians(this.gps_heading));
228 double c1 = Math.cos(Math.toRadians(this.gps_heading)); 208 double c1 = Math.cos(Math.toRadians(this.gps_heading));
229 double radius_x2 = (this.getWidth() / 2) - 34; 209 double radius_x2 = (this.getWidth() / 2) - 34;
230 double radius_y2 = (this.getHeight() / 2) - 34; 210 double radius_y2 = (this.getHeight() / 2) - 34;
231 double[] my_shape = {0.7, +0, 0, -1, -0.7, 0}; 211 double[] my_shape = { 0.7, +0, 0, -1, -0.7, 0 };
232 212
233 Path p = new Path(); 213 Path p = new Path();
234 for (int i = 0; i < 3; i++) 214 for (int i = 0; i < 3; i++)
235 { 215 {
236 if (i == 0) 216 if (i == 0)
237 { 217 {
238 //System.out.println("" + my_shape[(i + 1) * 2 - 2]); 218 //System.out.println("" + my_shape[(i + 1) * 2 - 2]);
239 //System.out.println("" + my_shape[(i + 1) * 2 - 1]); 219 //System.out.println("" + my_shape[(i + 1) * 2 - 1]);
240 p.moveTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 220 p.moveTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2), (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
241 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2),
242 (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
243 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
244 } 221 }
245 else 222 else
246 { 223 {
247 //System.out.println("" 224 //System.out.println(""
248 // + (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 225 // + (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2
249 // - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius)); 226 // - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius));
250 //System.out.println("" 227 //System.out.println(""
251 // + ((my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 228 // + ((my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
252 // + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius))); 229 // + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius)));
253 p.lineTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 230 p.lineTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2), (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
254 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2),
255 (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
256 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
257 } 231 }
258 } 232 }
259 p.close(); 233 p.close();
260 paint_gps.setStyle(Paint.Style.STROKE); 234 paint_gps.setStyle(Paint.Style.STROKE);
261 paint_gps.setStrokeWidth(4); 235 paint_gps.setStrokeWidth(4);
266 c.drawPath(p, paint_gps); 240 c.drawPath(p, paint_gps);
267 241
268 paint_gps.setTextSize(14); 242 paint_gps.setTextSize(14);
269 paint_gps.setStrokeWidth(1); 243 paint_gps.setStrokeWidth(1);
270 paint_gps.setColor(Color.parseColor("#00EE00")); 244 paint_gps.setColor(Color.parseColor("#00EE00"));
271 c.drawText("*gps fix* (" + this.used_sats + ")", this.getWidth() - 90, this 245 c.drawText("*gps fix* (" + this.used_sats + ")", this.getWidth() - 90, this.getHeight() - 17, paint_gps);
272 .getHeight() - 17, paint_gps);
273 } 246 }
274 } 247 }
275 } 248 }
276 else 249 else
277 { 250 {
284 int size = 16; 257 int size = 16;
285 double s1 = Math.sin(Math.toRadians(this.gps_heading)); 258 double s1 = Math.sin(Math.toRadians(this.gps_heading));
286 double c1 = Math.cos(Math.toRadians(this.gps_heading)); 259 double c1 = Math.cos(Math.toRadians(this.gps_heading));
287 double radius_x2 = (this.getWidth() / 2) - 34; 260 double radius_x2 = (this.getWidth() / 2) - 34;
288 double radius_y2 = (this.getHeight() / 2) - 34; 261 double radius_y2 = (this.getHeight() / 2) - 34;
289 double[] my_shape = {0.7, +0, 0, -1, -0.7, 0}; 262 double[] my_shape = { 0.7, +0, 0, -1, -0.7, 0 };
290 263
291 Path p = new Path(); 264 Path p = new Path();
292 for (int i = 0; i < 3; i++) 265 for (int i = 0; i < 3; i++)
293 { 266 {
294 if (i == 0) 267 if (i == 0)
295 { 268 {
296 //System.out.println("" + my_shape[(i + 1) * 2 - 2]); 269 //System.out.println("" + my_shape[(i + 1) * 2 - 2]);
297 //System.out.println("" + my_shape[(i + 1) * 2 - 1]); 270 //System.out.println("" + my_shape[(i + 1) * 2 - 1]);
298 p.moveTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 271 p.moveTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2), (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
299 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2),
300 (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
301 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
302 } 272 }
303 else 273 else
304 { 274 {
305 //System.out.println("" 275 //System.out.println(""
306 // + (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 276 // + (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2
307 // - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius)); 277 // - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius));
308 //System.out.println("" 278 //System.out.println(""
309 // + ((my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 279 // + ((my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
310 // + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius))); 280 // + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius)));
311 p.lineTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 281 p.lineTo((float) (my_shape[(i + 1) * 2 - 2] * size * c1 + this.getWidth() / 2 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2), (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
312 - my_shape[(i + 1) * 2 - 1] * size * s1 + s1 * radius_x2),
313 (float) (my_shape[(i + 1) * 2 - 1] * size * c1 + this.getHeight() / 2
314 + my_shape[(i + 1) * 2 - 2] * size * s1 - c1 * radius_y2));
315 } 282 }
316 } 283 }
317 p.close(); 284 p.close();
318 Paint paint_gps = new Paint(0); 285 paint_gps.reset();
319 paint_gps.setAntiAlias(true); 286 paint_gps.setAntiAlias(true);
320 paint_gps.setStyle(Paint.Style.STROKE); 287 paint_gps.setStyle(Paint.Style.STROKE);
321 paint_gps.setStrokeWidth(4); 288 paint_gps.setStrokeWidth(4);
322 paint_gps.setColor(Color.parseColor("#00EE00")); 289 paint_gps.setColor(Color.parseColor("#00EE00"));
323 c.drawPath(p, paint_gps); 290 c.drawPath(p, paint_gps);
327 294
328 } 295 }
329 } 296 }
330 297
331 // no gps fix 298 // no gps fix
332 Paint paint_gps = new Paint(0); 299 paint_gps.reset();
333 paint_gps.setAntiAlias(true); 300 paint_gps.setAntiAlias(true);
334 paint_gps.setColor(Color.parseColor("#EE0000")); 301 paint_gps.setColor(Color.parseColor("#EE0000"));
335 paint_gps.setStyle(Paint.Style.STROKE); 302 paint_gps.setStyle(Paint.Style.STROKE);
336 paint_gps.setTextSize(11); 303 paint_gps.setTextSize(11);
337 c.drawText("no gps fix (" + this.used_sats + ")", this.getWidth() - 90, 304 c.drawText("no gps fix (" + this.used_sats + ")", this.getWidth() - 90, this.getHeight() - 17, paint_gps);
338 this.getHeight() - 17, paint_gps);
339 305
340 } 306 }
341 307
342 // draw follow 308 // draw follow
343 c.drawBitmap(this.main_aagtl.follow_current, this.main_aagtl.follow_button_rect.left, 309 c.drawBitmap(this.main_aagtl.follow_current, this.main_aagtl.follow_button_rect.left, this.main_aagtl.follow_button_rect.top, null);
344 this.main_aagtl.follow_button_rect.top, null);
345 310
346 // draw arrow button 311 // draw arrow button
347 c.drawBitmap(this.main_aagtl.arrow_button, this.main_aagtl.arrow_button_rect.left, 312 c.drawBitmap(this.main_aagtl.arrow_button, this.main_aagtl.arrow_button_rect.left, this.main_aagtl.arrow_button_rect.top, null);
348 this.main_aagtl.arrow_button_rect.top, null);
349 313
314 if (!this.main_aagtl.has_hw_menu_button)
315 {
316 // draw emulated menu button
317 c.drawBitmap(this.main_aagtl.menu_button, this.main_aagtl.menu_button_rect.left, this.main_aagtl.menu_button_rect.top, null);
318
319 // Paint px = new Paint();
320 // px.setColor(Color.RED);
321 // px.setStyle(Style.STROKE);
322 // c.drawRect(this.main_aagtl.menu_button_rect_touch, px);
323
324 //
325 // paint.setAntiAlias(true);
326 // paint.setColor(Color.LTGRAY);
327 // paint.setStrokeWidth(4);
328 // paint.setAlpha(179);
329 // paint.setStyle(Paint.Style.FILL);
330 // c.drawRoundRect(this.main_aagtl.menu_button_rect, (int) 8f * aagtl.Global_dpi_factor, (int) 8f * aagtl.Global_dpi_factor, paint);
331 // paint.setColor(Color.BLACK);
332 // //
333 // paint.setStyle(Paint.Style.STROKE);
334 // paint.setStrokeWidth(1);
335 // paint.setAlpha(255);
336 // c.drawRoundRect(this.main_aagtl.menu_button_rect, (int) 8f * aagtl.Global_dpi_factor, (int) 8f * aagtl.Global_dpi_factor, paint);
337 //
338 // paint.setAntiAlias(true);
339 // paint.setTextSize(23 * aagtl.Global_dpi_factor);
340 // paint.setStrokeWidth(2);
341 // paint.setTextAlign(Paint.Align.CENTER);
342 // paint.setStyle(Paint.Style.FILL);
343 // paint.setAlpha(255);
344 // menu_text_path.reset();
345 // menu_text_path.moveTo(this.main_aagtl.menu_button_rect.left, this.main_aagtl.menu_button_rect.top + (this.main_aagtl.menu_button_rect.bottom - this.main_aagtl.menu_button_rect.top) / 2);
346 // menu_text_path.lineTo(this.main_aagtl.menu_button_rect.right, this.main_aagtl.menu_button_rect.top + (this.main_aagtl.menu_button_rect.bottom - this.main_aagtl.menu_button_rect.top) / 2);
347 // c.drawTextOnPath("MENU", menu_text_path, 0, 0, paint);
350 } 348 }
351 349 }
352} 350}

Legend:
Removed from v.3  
changed lines
  Added in v.4

   
Visit the aagtl Website