zsh_root
2024-01-02 7b595546af704983dbafcd0d385c8768ddacefc2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
package Frame;
import java.awt.BorderLayout;
import java.awt.Container;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.Vector;
import javax.swing.ComboBoxModel;
import javax.swing.DefaultComboBoxModel;
import javax.swing.ImageIcon;
import javax.swing.JComboBox;
import javax.swing.JInternalFrame;
import javax.swing.JTextField;
import javax.swing.event.InternalFrameEvent;
import javax.swing.event.InternalFrameListener;
import ColorAndFont.NothJPanel;
import ColorAndFont.UIColor;
import Method.GetNowTime;
import PbuliClass.JButtonModel;
import PbuliClass.JlableModel;
import PbuliClass.ShowMessage;
import PbuliClass.Systems;
import PbuliClass.jinternalFrame;
import tag.Tag_Dell;
import tbDataModel.TbMap;
import tbDataModel_Dell.Dell_tag_gas_jiaozhun_value;
import tbDataModel_Dell.Dell_tb_suanfa2;
import tbDataModel_Dell.JPanelModel1;
import tbDataModel_Dell.Map_Dell;
import urt.GNSS2jiajiao;
import urt.GnssToXY;
import urt.xytognss;
import urt.xytoutm;
/**¾àÀë·ÖÎö*/
public class Tool extends jinternalFrame {
    /**
     *
     */
    private static final long serialVersionUID = 1L;
    jinternalFrame jinerFrame=null;
    JInternalFrame jinFrame=null;
    NothJPanel mb=null;//±±²¿Ãæ°å
 
    JlableModel Jl_b0=new JlableModel("Aµã¾­;γ;x;y");
    JlableModel Jl_bd=new JlableModel("Bµã¾­;γ;x;y");
    JTextField  Jt_jd0=null;
    JTextField  Jt_wd0=null;
 
    JlableModel Jl_b3=new JlableModel("Ô­µãX¡¢Y×ø±ê");
    JTextField  Jt_x=null;
    JTextField  Jt_y=null;
    
    //¶Èת¶È·Ö
    JTextField  Jt_d2dm=null;
    JButtonModel jbt_d2dm=null;
 
    JlableModel  Jl_b1=new JlableModel("¾­Î³¶ÈתX¡¢Y×ø±ê");
    JlableModel  Jl_jd=new JlableModel("¾­¶È:");
    JlableModel  Jl_wd=new JlableModel("γ¶È:");
    JlableModel  Jl_jg=new JlableModel("½á¹û:");
    JTextField  Jt_jd=null;
    JTextField  Jt_wd=null;
    JTextField  Jt_jg=null;
 
    JlableModel  Jl_b2=new JlableModel("¼ÆËã2µã¼Ð½Ç");
    JlableModel  Jl_jwd1=new JlableModel("µã1¾­¡¢Î³¶È:");
    JlableModel  Jl_jwd2=new JlableModel("µã2¾­¡¢Î³¶È:");
    JlableModel  Jl_jg1=new JlableModel("½á¹û:");
    JTextField  Jt_jd1=null;
    JTextField  Jt_wd1=null;
    JTextField  Jt_jd2=null;
    JTextField  Jt_wd2=null;
    JTextField  Jt_jg1=null;
 
    JlableModel  Jl_b4=new JlableModel("X¡¢Y×ø±êתΪ¾­Î³¶È");
    JlableModel  Jl_x1=new JlableModel("X¡¢Y×ø±ê:");
    JlableModel  Jl_y1=new JlableModel("½á¹û:");
    JTextField  Jt_x1=null;
    JTextField  Jt_y1=null;
    JTextField  Jt_jg3=null;
 
 
    JButtonModel Jbt_jisuan=null;//¼ÆËã°´Å¥
    JButtonModel Jbt_jisuan1=null;//¼ÆËã°´Å¥
    JButtonModel Jbt_jisuan3=null;//¼ÆËã°´Å¥
 
    JPanelModel1 mp1=null;//»ù´¡ÉèÖÃÃæ°å
 
    JlableModel  Jl_jt=new JlableModel("Ñ¡Ôñ±êÇ©:");
    JComboBox<String> tagAll=null;//ËùÓбêÇ©µÄ¼¯ºÏ
 
    JlableModel  Jl_tag_gao=new JlableModel("±êÇ©¸ß¶È:");
    static  JTextField  Jt_tag_gao=new JTextField();
    
 
    JlableModel  Jl_tag_gas=new JlableModel("TgÆøÑ¹:");
    static  JTextField  Jt_tag_gas=new JTextField();
 
    JlableModel  Jl_anchor_gas=new JlableModel("AgÆøÑ¹:");
    static JTextField  Jt_anchor_gas=new JTextField();
 
    static JTextField  Jt_jiao_zhun_qing_kuang=new JTextField();//У׼Çé¿ö
 
 
    JButtonModel jiaozhun_gas_button=null;//Ð£×¼ÆøÑ¹°´Å¥    
    static String tagischose="0000";
    static String acischose="0000";
 
    TbMap mp=Map_Dell.getmp1();
    //»ùÕ¾ºÍ±êÇ©µÄ¸ß¶È²î
    static int ac_tagh=0;
    static int tagnum_online=0;
    int  tagoknum=0;//È«²¿Ð޸ıêÇ©ÆøÑ¹Ê±ºòд¹ýµÄ±êÇ©ÊýÁ¿
    static Vector<String> oktaggas=null;
    //ËùÓÐÔÚÏß±êÇ©µÄ¼¯ºÏ
    static Vector<String> tagidonlie=new Vector<String>();
 
 
 
    public Tool() {//¹¹Ôì·½·¨
        Container rq=getContentPane();//»ñÈ¡ÈÝÆ÷
        rq.setLayout(new BorderLayout());
        rq.setBackground(UIColor.getNorth_color());
        if (Map_Dell.getMap_vector().size()==0){
            ShowMessage.zidingyi_24("µØÍ¼²»´æÔÚ,ÇëÏÈÌí¼ÓµØÍ¼");
            this.dispose();
            return;
        }
        this.addInternalFrameListener(new InternalFrameListener() {
 
            @Override
            public void internalFrameOpened(InternalFrameEvent e) {
            }
 
            @Override
            public void internalFrameIconified(InternalFrameEvent e) {
            }
 
            @Override
            public void internalFrameDeiconified(InternalFrameEvent e) {
            }
 
            @Override
            public void internalFrameDeactivated(InternalFrameEvent e) {
            }
 
            @Override
            public void internalFrameClosing(InternalFrameEvent e) {
                Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_isstart(false);
            }
 
            @Override
            public void internalFrameClosed(InternalFrameEvent e) {
            }
 
            @Override
            public void internalFrameActivated(InternalFrameEvent e) {
            }
        });
        String title="¿ì½Ý¼ÆËã";
        if(Systems.sys().getLanguage().equals("English")) {
            title="FASTTOOL";
        }
        this.setTitle(title);
        this.setFrameIcon(new ImageIcon("image/icon/debug.png"));//ÉèÖô°Ìåͼ±ê
        this.setBounds(175,0,850,600);
        rq.add(getNorthPanel(),BorderLayout.CENTER);
        Jt_tag_gao.setToolTipText("±êÇ©¸ß¶ÈΪµ±Ç°±êÇ©·ÅµÄ¸ß¶Èµ¥Î»ÀåÃ×");
 
    }
 
 
    /**»ñÈ¡±±²¿Ãæ°åµÄ·½·¨*/
    public NothJPanel getNorthPanel() {
        if(mb==null) {
            mb=new NothJPanel();
            mb.setLayout(null);
            int a=20;
            int y0=10;
            int y=y0+35+95;
 
            mb.add(Jl_b0);
            Jl_b0.setBounds(a,y0,100,25);
            mb.add(getJt_jd0());
 
            Jt_jd0.setBounds(a+100,y0,240,25);
            mb.add(getJt_wd0());
 
            mb.add(Jl_bd);
            Jl_bd.setBounds(a+360,y0,100,25);
            Jt_wd0.setBounds(a+460,y0,280,25);
            mb.add(Jl_bd);
 
 
            mb.add(Jl_b3);
            Jl_b3.setBounds(a,y0+40,100,25);
            mb.add(getJt_x());
            Jt_x.setBounds(a+100,y0+40, 100,25);
            mb.add(getJt_y());
            Jt_y.setBounds(a+210,y0+40, 100,25);
            
            //¶Èת¶È·Ö¼ÆËã
            JlableModel Jl_ba=new JlableModel("¶Èת¶È·Ö£º");
            mb.add(Jl_ba);
            mb.add(getJt_d2dm());
            mb.add(getJbt_d2dm());
            Jl_ba.setBounds(a+360,y0+40, 80,25);
            Jt_d2dm.setBounds(a+440,y0+40,200,25);
            jbt_d2dm.setBounds(a+650,y0+40, 100,25);
 
 
            //¾­¶È
            mb.add(Jl_b1);
            Jl_b1.setBounds(a,y-40,200,25);
 
            mb.add(Jl_jd);
            Jl_jd.setBounds(a,y,50,25);
            mb.add(getJt_jd());
            Jt_jd.setBounds(a+50,y, 100,25);
 
            //γ¶È
            mb.add(Jl_wd);
            Jl_wd.setBounds(a+170, y,50,25);
            mb.add(getJt_wd());
            Jt_wd.setBounds(a+210,y, 100,25);
 
            //½á¹û
            mb.add(Jl_jg);
            Jl_jg.setBounds(a+330,y,50,25);
            mb.add(getJt_jg());
            Jt_jg.setBounds(a+370,y, 200,25);
 
            //¼ÆËã
            mb.add(getJbt_jisuan());
            Jbt_jisuan.setBounds(a+580,y,80,25);
 
 
            int y2=y+25+20;
            mb.add(Jl_b2);
            Jl_b2.setBounds(a,y2,200,25);
 
            int y3=y+50+30;
            mb.add(Jl_jwd1);
            Jl_jwd1.setBounds(a,y3,100,25);
            mb.add(getJt_jd1());
            mb.add(getJt_wd1());
            Jt_jd1.setBounds(a+100,y3,80,25);
            Jt_wd1.setBounds(a+190,y3,80,25);
 
            mb.add(Jl_jwd2);
            Jl_jwd2.setBounds(a+280,y3,100,25);
            mb.add(getJt_jd2());
            mb.add(getJt_wd2());
            Jt_jd2.setBounds(a+380,y3,80,25);
            Jt_wd2.setBounds(a+470,y3,80,25);
 
 
            //½á¹û
            mb.add(Jl_jg1);
            Jl_jg1.setBounds(a+560,y3,50,25);
            mb.add(getJt_jg1());
            Jt_jg1.setBounds(a+610,y3,50,25);
            //¼ÆËã
            mb.add(getJbt_jisuan1());
            Jbt_jisuan1.setBounds(a+670,y3,80,25);
 
            int y7=y3+50;
            int y8=y7+40;
            mb.add(Jl_b4);
            mb.add(Jl_x1);
            Jl_b4.setBounds(a,y7,200,25);
            Jl_x1.setBounds(a,y8,100,25);
            mb.add(getJt_x1());
            Jt_x1.setBounds(a+100,y8, 100,25);
            mb.add(getJt_y1());
            Jt_y1.setBounds(a+220,y8, 100,25);
 
            mb.add(Jl_y1);
            Jl_y1.setBounds(a+330,y8,50,25);
            mb.add(getJt_jg3());
            Jt_jg3.setBounds(a+380,y8,200,25);
 
 
            mb.add(getJbt_jisuan3());
            Jbt_jisuan3.setBounds(a+590,y8,100,25);
 
            mb.add(getMp1());
            mp1.setBounds(a, y8+35, 790, 150);
 
 
        }
        return mb;
    }
 
    public JTextField getJt_jd0() {
        if(Jt_jd0==null) {
            Jt_jd0=new JTextField();
            if(mp !=null) {
                String a=mp.getBaoliu1();
                Jt_jd0.setText(a);
            }
        }
        return Jt_jd0;
    }
 
 
    public JTextField getJt_wd0() {
        if(Jt_wd0==null) {
            Jt_wd0=new JTextField();
            if(mp !=null) {
                String a=mp.getBaoliu2();
                Jt_wd0.setText(a);
            }
        }
        return Jt_wd0;
    }
 
 
 
    public JTextField getJt_x() {
        if(Jt_x==null) {
            TbMap map = Map_Dell.get_map("0");
            if (map==null){
                ShowMessage.zidingyi("µØÍ¼²»´æÔÚ");
                return null;
            }
            String a=String.valueOf(map.x0_length);
            Jt_x=new JTextField(a);
        }
        return Jt_x;
    }
 
    public JTextField getJt_y() {
        if(Jt_y==null) {
            String b=String.valueOf(Map_Dell.get_map("0").getY0_width());
            Jt_y=new JTextField(b);
        }
        return Jt_y;
    }
 
    public JTextField getJt_x1() {
        if(Jt_x1==null) {
            Jt_x1=new JTextField();
        }
        return Jt_x1;
    }
 
    public JTextField getJt_y1() {
        if(Jt_y1==null) {
            Jt_y1=new JTextField();
        }
        return Jt_y1;
    }
 
    public JTextField getJt_jg3() {
        if(Jt_jg3==null) {
            Jt_jg3=new JTextField();
        }
        return Jt_jg3;
    }
 
 
 
    public JTextField getJt_jd() {
        if(Jt_jd==null) {
            Jt_jd=new JTextField();
        }
        return Jt_jd;
    }
 
 
    public JTextField getJt_wd() {
        if(Jt_wd==null) {
            Jt_wd=new JTextField();
        }
        return Jt_wd;
    }
 
 
    public JTextField getJt_jg() {
        if(Jt_jg==null) {
            Jt_jg=new JTextField();
        }
        return Jt_jg;
    }
 
    public JTextField getJt_jd1() {
        if(Jt_jd1==null) {
            Jt_jd1=new JTextField();
        }
        return Jt_jd1;
    }
 
 
    public JTextField getJt_wd1() {
        if(Jt_wd1==null) {
            Jt_wd1=new JTextField();
        }
        return Jt_wd1;
    }
 
    public JTextField getJt_jd2() {
        if(Jt_jd2==null) {
            Jt_jd2=new JTextField();
        }
        return Jt_jd2;
    }
 
 
    public JTextField getJt_wd2() {
        if(Jt_wd2==null) {
            Jt_wd2=new JTextField();
        }
        return Jt_wd2;
    }
 
    public JTextField getJt_jg1() {
        if(Jt_jg1==null) {
            Jt_jg1=new JTextField();
        }
        return Jt_jg1;
    }
 
    public JButtonModel getJbt_jisuan() {
        if(Jbt_jisuan==null) {
            Jbt_jisuan=new JButtonModel("¼ÆËãXY");
            Jbt_jisuan.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    String yd=Jt_jd0.getText().trim();
                    String b=Jt_wd0.getText().trim();
 
                    String[] A1=yd.split(";");
                    String[] B1=b.split(";");
 
 
                    if(B1.length !=4) {
                        ShowMessage.zidingyi_24("ÊäÈ볤¶È²»¶Ô£¬Ó¢ÎÄÏÂ;·Ö¸ô");
                        return;
                    }
 
 
                    String jd1=Jt_jd.getText().trim();
                    String wd1=Jt_wd.getText().trim();
 
                    if(jd1.length()>3 || wd1.length()>3) {
                        int[] xy=GnssToXY.gps_xy(
                                A1,
                                B1,
                                jd1,
                                wd1);
                        String a="x="+xy[0]+"; y="+xy[1];
                        Jt_jg.setText(a);
 
                    }else {
                        ShowMessage.zidingyi("ÇëÊäÈëÕýÈ·µÄ¾­Î³¶ÈÖµ");
                    }
 
                }
            });
        }
        return Jbt_jisuan;
    }
 
    public JButtonModel getJbt_jisuan1() {
        if(Jbt_jisuan1==null) {
            Jbt_jisuan1=new JButtonModel("¼ÆËã½Ç¶È");
            Jbt_jisuan1.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    String jd1=Jt_jd1.getText().trim();
                    String wd1=Jt_wd1.getText().trim();
                    String jd2=Jt_jd2.getText().trim();
                    String wd2=Jt_wd2.getText().trim();
                    if(jd1.length()>0 || jd2.length()>0) {
                        String jd=GNSS2jiajiao.GetAzimuth(jd1,wd1,jd2,wd2);
                        Jt_jg1.setText(String.valueOf(jd));
 
                    }else {
                        ShowMessage.zidingyi("ÇëÊäÈëÕýÈ·µÄ¾­Î³¶ÈÖµ");
                    }
 
                }
            });
        }
        return Jbt_jisuan1;
    }
 
    public JButtonModel getJbt_jisuan3() {
        if(Jbt_jisuan3==null) {
            Jbt_jisuan3=new JButtonModel("¼ÆË㾭γ¶È");
            Jbt_jisuan3.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
 
                    String x=Jt_x1.getText().replaceAll(" ","");
                    String y=Jt_y1.getText().replaceAll(" ","");
                    if(x.length()==0) {
                        ShowMessage.zidingyi("x×ø±ê²»ÄÜΪ¿Õ");
                        return;
                    }
 
                    if(y.length()==0) {
                        ShowMessage.zidingyi("y×ø±ê²»ÄÜΪ¿Õ");
                        return;
                    }
 
                    String yd=Jt_jd0.getText().trim();
                    String b=Jt_wd0.getText().trim();
 
                    String[] A=yd.split(";");
                    String[] B=b.split(";");
 
                    if(A.length<4 || B.length<4 ) {
                        if(Dell_tb_suanfa2.isGnss2xyopen()) {
                            ShowMessage.zidingyi_24("µØÍ¼ABµã¾­Î³¶ÈÉèÖÃÓдí,Ëã·¨ÅäÖÿªÆôÁËGNSSתXY×ø±ê");
                        }
                        return;
                    }else {
                        double lon_a=Double.parseDouble(A[0]);//A¾­¶È
                        double lat_a=Double.parseDouble(A[1]);//Aγ¶È
                        double xa=Double.parseDouble(A[2]);
                        double ya=Double.parseDouble(A[3]);
                        double lon_b=Double.parseDouble(B[0]);//B¾­¶È
                        double lat_b=Double.parseDouble(B[1]);//Bγ¶È
                        double xb=Double.parseDouble(B[2]);
                        double yb=Double.parseDouble(B[3]);
                        double[] xycs=GnssToXY.initiize_ublox_AB2(lat_a, lon_a,lat_b, lon_b,xa,ya,xb,yb);
                        String jwd[]=xytoutm.xy2jwd(x, y,xycs);
                        String a=jwd[3]+";"+jwd[2];
                        Jt_jg3.setText(a);
                    }
                }
            });
        }
        return Jbt_jisuan3;
    }
 
 
    public JPanelModel1 getMp1() {
        if(mp1==null) {
            mp1=new JPanelModel1("¸ß¶ÈÒ»¼üУ׼");
            mp1.setBackground(null);
            int x=30;
            int y=30;
            int height=25;
 
            mp1.add(Jl_jt);
            mp1.add(getTagAll());
 
            mp1.add(Jl_tag_gao);
            mp1.add(Jt_tag_gao);
 
            mp1.add(Jl_tag_gas);
            mp1.add(Jt_tag_gas);
 
            mp1.add(Jl_anchor_gas);
            mp1.add(Jt_anchor_gas);
 
            mp1.add(Jt_jiao_zhun_qing_kuang);
            mp1.add(getjiaozhun_gas_button());
 
            int x1=x+80;
            int x2=x1+150;
            int x3=x2+80;
            int x4=x3+110;
            int x5=x4+60;
            int x6=x5+110;
            int x7=x6+60;
            
            int y1=height+y+30;    
            Jl_jt.setBounds(x, y,80, height);//Ñ¡Ôñ±êÇ©
            Jt_jiao_zhun_qing_kuang.setBounds(x, y1,630, height);//Ñ¡Ôñ»ùÕ¾
            
            
            tagAll.setBounds(x1,y,120, height);//Ñ¡Ôñ±êÇ©ÏÂÀ­¿ò
            
            Jl_tag_gao.setBounds(x2,y,80, height);//µ±Ç°¸ß¶È
            Jt_tag_gao.setBounds(x3,y,80, height);
 
            Jl_tag_gas.setBounds(x4,y, 60, height);
            Jt_tag_gas.setBounds(x5,y, 80, height);
 
            Jl_anchor_gas.setBounds(x6,y, 60, height);
            Jt_anchor_gas.setBounds(x7,y,100, height);
 
            jiaozhun_gas_button.setBounds(x7,y1,100, height);
 
        }
        return mp1;
    }
 
 
 
    public JComboBox<String> getTagAll() {
        if( tagAll==null) {
            tagAll=new JComboBox<String>() ;
            tagAll.setFont(new Font("΢ÈíÑźÚ", Font.PLAIN, 12));//ÉèÖÃ×ÖÌå
            ComboBoxModel<String > coModel=new DefaultComboBoxModel<>(Tag_Dell.GetTagAllstr());//ÏÂÀ­ÁбíÄ£ÐÍ
            tagAll.setModel(coModel);
            tagAll.setEnabled(true);
            //ÏÂÀ­¿ò¿ÉÒÔÊäÈë
            tagAll.setEditable(true);
            tagAll.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent arg0) {
                    tagischose=(String) tagAll.getSelectedItem();
                }
            });
        }
        return tagAll;
    }
 
 
    public JButtonModel getjiaozhun_gas_button() {
        if(jiaozhun_gas_button==null) {
            jiaozhun_gas_button=new JButtonModel("Ò»¼üУ׼");
            jiaozhun_gas_button.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    if( !Dell_tag_gas_jiaozhun_value.isGas_jiaozhun_isstart()) {                        
                        //±êÇ©µ±Ç°¸ß¶È
                        String tagg=Jt_tag_gao.getText().trim();
                        if(tagg.length()<2) {
                            ShowMessage.zidingyi("±êÇ©µ±Ç°¸ß¶È²»ÄÜΪ¿Õ");
                            return;
                        }
                        int tagnowh=Integer.parseInt(tagg);
                        tagischose=(String) tagAll.getSelectedItem();
 
                        if(!tagischose.equals("ËùÓбêÇ©")) {    //²»ÊÇËùÓбêÇ©µÄʱºò
                            Dell_tag_gas_jiaozhun_value.alertallgasstate1(tagischose,tagnowh);
                        }else {
                            Jt_tag_gas.setText("");
                            Dell_tag_gas_jiaozhun_value.alertallgasstate1("ALL",tagnowh);
                        }
                        Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_isstart(true);//ÆøÑ¹Ð£×¼¿ªÊ¼
                        Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_start_time(GetNowTime.now());
                        jiaozhun_gas_button.setText("½áÊøÐ£×¼");
                    }else {
                        Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_isstart(false);//ÆøÑ¹Ð£×¼¿ªÊ¼
                        Jt_tag_gao.setText("");
                        Jt_tag_gas.setText("");
                        Jt_anchor_gas.setText("");
                        jiaozhun_gas_button.setText("¿ªÊ¼Ð£×¼");
                    }
 
                }
            });
        }
        return jiaozhun_gas_button;
    }
 
    
 
    /**´¦Àí¸ß¶ÈУ׼ָÁî*/
    //¸ß¶ÈУ׼¿ØÖÆÖ¸Áî
    //Ö¸Áî¸ñʽ£º55BB,HeightModify,tagid,tagidheight,END
    //Ö¸Áî˵Ã÷£º
    //55BB£ºÎª°üÍ·£»
    //HeightModify£º¸ß¶ÈÐÞÕý
    //tagid£ºÐèÒªÐÞÕýµÄ±êÇ©ID£¬ALL±íʾȫ²¿ÐÞÕý
    //tagidheight£º±êÇ©µ±Ç°¸ß¶È£¬µ¥Î»ÀåÃ×
    //END£º½áÊø±êÖ¾
    //ʾÁУº55BB,HeightModify,1001,100,END
    //ʾÁУº55BB,HeightModify,ALL,100,END
    public static void HeightModify(String message) {
        String a1=message.toUpperCase();
        if(a1.startsWith("55BB")) {
            String[] msb=a1.split(",");
            if(msb[1].equals("HEIGHTMODIFY")) {
                String tagid=msb[2];
                String tag_now_gao1=msb[3];//±êÇ©µ±Ç°Ëù´¦µÄ¸ß¶È
                int tag_now_gao=Integer.parseInt(tag_now_gao1);
                Dell_tag_gas_jiaozhun_value.alertallgasstate1(tagid,tag_now_gao);
                Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_isstart(true);//ÆøÑ¹Ð£×¼¿ªÊ¼
                Dell_tag_gas_jiaozhun_value.setGas_jiaozhun_start_time(GetNowTime.now());
            }
        }
    }
 
 
    public static JTextField getJt_jiao_zhun_qing_kuang() {
        return Jt_jiao_zhun_qing_kuang;
    }
 
 
    public static void setJt_jiao_zhun_qing_kuang(JTextField jt_jiao_zhun_qing_kuang) {
        Jt_jiao_zhun_qing_kuang = jt_jiao_zhun_qing_kuang;
    }
 
 
    public static JTextField getJt_tag_gas() {
        return Jt_tag_gas;
    }
 
 
    public static JTextField getJt_anchor_gas() {
        return Jt_anchor_gas;
    }
 
 
    public static void setJt_tag_gas(JTextField jt_tag_gas) {
        Jt_tag_gas = jt_tag_gas;
    }
 
 
    public static void setJt_anchor_gas(JTextField jt_anchor_gas) {
        Jt_anchor_gas = jt_anchor_gas;
    }
 
 
    public JTextField getJt_d2dm() {
        if(Jt_d2dm==null) {
            Jt_d2dm=new JTextField();
        }
        return Jt_d2dm;
    }
 
 
 
    public JButtonModel getJbt_d2dm() {
        if(jbt_d2dm==null) {
            jbt_d2dm=new JButtonModel("¶Èת¶È·Ö");
            jbt_d2dm.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    String a=Jt_d2dm.getText();
                    if(a.length()>4) {
                        if(a.split("=").length>1) {
                            ShowMessage.zidingyi(a+"ÊäÈëµÄÊý¾ÝÓÐÎÊÌâ...");
                            return;
                        }
                        double adb=Double.parseDouble(a);
                        String wd=String .format("%.6f",xytognss.ublox_d2dm(adb));
                        Jt_d2dm.setText(a+"="+wd);
                    }else {
                        ShowMessage.zidingyi(a+"ÊäÈëµÄÊý¾ÝÓÐÎÊÌâ...");
                        return;
                    }                    
                }
            });
        }
        return jbt_d2dm;
    }
 
 
    public void setJbt_d2dm(JButtonModel jbt_d2dm) {
        this.jbt_d2dm = jbt_d2dm;
    }
 
}