프로젝트

일반

사용자정보

개정판 e66f22eb

IDe66f22eb785bdd60721db5930d8bcc1d7453ca99
상위 d7123191
하위 65246dc9

KangIngu 이(가) 6년 이상 전에 추가함

- Polyline,Polygon,PolygonCloud 그리기 오류

- 컨트롤이 문서와 문서 밖 영역에 걸쳐 있을때 처리 방법을 통일

차이점 보기:

KCOM/Views/MainMenu.xaml.cs
3081 3081
                        {
3082 3082
                            if (mouseButtonDown == MouseButton.Left)
3083 3083
                            {
3084
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3085
                                {
3084
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3085
                                //{
3086 3086
                                    if (currentControl is RectangleControl)
3087 3087
                                    {
3088
                                        if(IsGetoutpoint((currentControl as RectangleControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3089
                                        {
3090
                                            return;
3091
                                        }
3092

  
3088 3093
                                        CreateControl();
3089 3094

  
3090 3095
                                        (currentControl as RectangleControl).ApplyOverViewData();
......
3106 3111

  
3107 3112
                                        currentControl.SetValue(Canvas.ZIndexProperty, 3);
3108 3113
                                    }
3109
                                }
3114
                                //}
3110 3115
                            }
3111 3116
                        }
3112 3117
                        break;
......
3114 3119
                        {
3115 3120
                            if (mouseButtonDown == MouseButton.Left)
3116 3121
                            {
3117
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3118
                                {
3122
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3123
                                //{
3119 3124
                                    if (currentControl is RectCloudControl)
3120 3125
                                    {
3126
                                        if (IsGetoutpoint((currentControl as RectCloudControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3127
                                        {
3128
                                            return;
3129
                                        }
3130

  
3121 3131
                                        CreateControl();
3122 3132

  
3123 3133
                                        (currentControl as RectCloudControl).ApplyOverViewData();
......
3136 3146
                                        currentControl.IsNew = true;
3137 3147
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3138 3148
                                    }
3139
                                }
3149
                                //}
3140 3150
                            }
3141 3151
                        }
3142 3152
                        break;
......
3144 3154
                        {
3145 3155
                            if (mouseButtonDown == MouseButton.Left)
3146 3156
                            {
3147
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3148
                                {
3157
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3158
                                //{
3149 3159
                                    if (currentControl is CircleControl)
3150 3160
                                    {
3161
                                        if (IsGetoutpoint((currentControl as CircleControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3162
                                        {
3163
                                            return;
3164
                                        }
3165

  
3151 3166
                                        CreateControl();
3152 3167

  
3153 3168
                                        (currentControl as CircleControl).ApplyOverViewData();
......
3165 3180
                                        currentControl.IsNew = true;
3166 3181
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3167 3182
                                    }
3168
                                }
3183
                                //}
3169 3184
                            }
3170 3185
                        }
3171 3186
                        break;
......
3173 3188
                        {
3174 3189
                            if (mouseButtonDown == MouseButton.Left)
3175 3190
                            {
3176
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3177
                                {
3191
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3192
                                //{
3178 3193
                                    if (currentControl is TriControl)
3179 3194
                                    {
3180 3195
                                        var content = currentControl as TriControl;
......
3184 3199
                                        }
3185 3200
                                        else
3186 3201
                                        {
3202
                                            if (IsGetoutpoint((currentControl as TriControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3203
                                            {
3204
                                                return;
3205
                                            }
3206

  
3187 3207
                                            CreateControl();
3188 3208

  
3189 3209
                                            (currentControl as TriControl).ApplyOverViewData();
......
3203 3223
                                        currentControl.IsNew = true;
3204 3224
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3205 3225
                                    }
3206
                                }
3226
                                //}
3207 3227
                            }
3208 3228
                        }
3209 3229
                        break;
......
3211 3231
                        {
3212 3232
                            if (mouseButtonDown == MouseButton.Left)
3213 3233
                            {
3214
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3215
                                {
3234
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3235
                                //{
3216 3236
                                    if (currentControl is LineControl)
3217 3237
                                    {
3238
                                        if (IsGetoutpoint((currentControl as LineControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3239
                                        {
3240
                                            return;
3241
                                        }
3242

  
3218 3243
                                        CreateControl();
3219 3244

  
3220 3245
                                        (currentControl as LineControl).ApplyOverViewData();
......
3234 3259
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3235 3260
                                        this.MainAngle.Visibility = Visibility.Visible;
3236 3261
                                    }
3237
                                }
3262
                                //}
3238 3263
                            }
3239 3264
                        }
3240 3265
                        break;
......
3242 3267
                        {
3243 3268
                            if (mouseButtonDown == MouseButton.Left)
3244 3269
                            {
3245
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3246
                                {
3270
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3271
                                //{
3247 3272
                                    if (currentControl is LineControl)
3248 3273
                                    {
3274
                                        if (IsGetoutpoint((currentControl as LineControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3275
                                        {
3276
                                            return;
3277
                                        }
3278

  
3249 3279
                                        CreateControl();
3250 3280

  
3251 3281
                                        (currentControl as LineControl).ApplyOverViewData();
......
3265 3295
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3266 3296
                                        this.MainAngle.Visibility = Visibility.Visible;
3267 3297
                                    }
3268
                                }
3298
                                //}
3269 3299
                            }
3270 3300
                        }
3271 3301
                        break;
......
3273 3303
                        {
3274 3304
                            if (mouseButtonDown == MouseButton.Left)
3275 3305
                            {
3276
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3277
                                {
3306
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3307
                                //{
3278 3308
                                    if (currentControl is LineControl)
3279 3309
                                    {
3310
                                        if (IsGetoutpoint((currentControl as LineControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3311
                                        {
3312
                                            return;
3313
                                        }
3314

  
3280 3315
                                        CreateControl();
3281 3316

  
3282 3317
                                        (currentControl as LineControl).ApplyOverViewData();
......
3296 3331
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3297 3332
                                        this.MainAngle.Visibility = Visibility.Visible;
3298 3333
                                    }
3299
                                }
3334
                                //}
3300 3335
                            }
3301 3336
                        }
3302 3337
                        break;
......
3304 3339
                        {
3305 3340
                            if (mouseButtonDown == MouseButton.Left)
3306 3341
                            {
3307
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3308
                                {
3342
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3343
                                //{
3309 3344
                                    if (currentControl is LineControl)
3310 3345
                                    {
3346
                                        if (IsGetoutpoint((currentControl as LineControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3347
                                        {
3348
                                            return;
3349
                                        }
3350

  
3311 3351
                                        CreateControl();
3312 3352

  
3313 3353
                                        (currentControl as LineControl).ApplyOverViewData();
......
3326 3366
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3327 3367
                                        this.MainAngle.Visibility = Visibility.Visible;
3328 3368
                                    }
3329
                                }
3369
                                //}
3330 3370
                            }
3331 3371
                        }
3332 3372
                        break;
......
3334 3374
                        {
3335 3375
                            if (mouseButtonDown == MouseButton.Left)
3336 3376
                            {
3337
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3338
                                {
3377
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3378
                                //{
3339 3379
                                    if (currentControl is LineControl)
3340 3380
                                    {
3381
                                        if (IsGetoutpoint((currentControl as LineControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3382
                                        {
3383
                                            return;
3384
                                        }
3341 3385
                                        CreateControl();
3342 3386

  
3343 3387
                                        (currentControl as LineControl).ApplyOverViewData();
......
3356 3400
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3357 3401
                                        this.MainAngle.Visibility = Visibility.Visible;
3358 3402
                                    }
3359
                                }
3403
                                //}
3360 3404
                            }
3361 3405
                        }
3362 3406
                        break;
......
3368 3412

  
3369 3413
                                if (mouseButtonDown == MouseButton.Right)
3370 3414
                                {
3415
                                    if (IsGetoutpoint((currentControl as PolygonControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3416
                                    {
3417
                                        return;
3418
                                    }
3419

  
3371 3420
                                    CreateControl();
3372 3421

  
3373 3422
                                    (currentControl as PolygonControl).ApplyOverViewData();
......
3397 3446
                                        //PointC = new StylusPointSet()
3398 3447
                                    };
3399 3448

  
3400
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3401
                                    {
3449
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3450
                                    //{
3402 3451
                                        var polygonControl = (currentControl as PolygonControl);
3403 3452
                                        currentControl.CommentID = Save.shortGuid();
3404 3453
                                        currentControl.MarkupInfoID = App.Custom_ViewInfoId;
......
3409 3458
                                        //polygonControl.PointC.pointSet.Add(canvasDrawingMouseDownPoint);
3410 3459
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
3411 3460
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
3412
                                    }
3461
                                    //}
3413 3462
                                }
3414 3463
                            }
3415 3464
                        }
......
3418 3467
                        {
3419 3468
                            if (mouseButtonDown == MouseButton.Left)
3420 3469
                            {
3421
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3422
                                {
3470
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3471
                                //{
3423 3472
                                    if (currentControl is ArcControl)
3424 3473
                                    {
3474
                                        if (IsGetoutpoint((currentControl as ArcControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3475
                                        {
3476
                                            return;
3477
                                        }
3478

  
3425 3479
                                        CreateControl();
3426 3480

  
3427 3481
                                        (currentControl as ArcControl).ApplyOverViewData();
......
3440 3494
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3441 3495
                                        this.MainAngle.Visibility = Visibility.Visible;
3442 3496
                                    }
3443
                                }
3497
                                //}
3444 3498
                            }
3445 3499
                            else if (mouseButtonDown == MouseButton.Right)
3446 3500
                            {
......
3457 3511
                        {
3458 3512
                            if (mouseButtonDown == MouseButton.Left)
3459 3513
                            {
3460
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3461
                                {
3514
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3515
                                //{
3462 3516
                                    if (currentControl is ArcControl)
3463 3517
                                    {
3518
                                        if (IsGetoutpoint((currentControl as ArcControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3519
                                        {
3520
                                            return;
3521
                                        }
3522

  
3464 3523
                                        CreateControl();
3465 3524

  
3466 3525
                                        (currentControl as ArcControl).ApplyOverViewData();
......
3480 3539
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3481 3540
                                        this.MainAngle.Visibility = Visibility.Visible;
3482 3541
                                    }
3483
                                }
3542
                                //}
3484 3543
                            }
3485 3544
                            else if (mouseButtonDown == MouseButton.Right)
3486 3545
                            {
......
3492 3551
                        {
3493 3552
                            if (mouseButtonDown == MouseButton.Left)
3494 3553
                            {
3495
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3496
                                {
3554
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3555
                                //{
3497 3556

  
3498 3557
                                    if (currentControl is ArrowControl_Multi)
3499 3558
                                    {
......
3511 3570
                                        }
3512 3571
                                        else
3513 3572
                                        {
3573
                                            if (IsGetoutpoint((currentControl as ArrowControl_Multi).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3574
                                            {
3575
                                                return;
3576
                                            }
3577

  
3514 3578
                                            CreateControl();
3515 3579

  
3516 3580
                                            (currentControl as ArrowControl_Multi).ApplyOverViewData();
......
3531 3595
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3532 3596
                                        this.MainAngle.Visibility = Visibility.Visible;
3533 3597
                                    }
3534
                                }
3598
                                //}
3535 3599
                            }
3536 3600
                        }
3537 3601
                        break;
......
3551 3615
                                }
3552 3616
                                else
3553 3617
                                {
3618
                                    if (IsGetoutpoint((currentControl as CloudControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3619
                                    {
3620
                                        return;
3621
                                    }
3622

  
3554 3623
                                    CreateControl();
3555 3624

  
3556 3625
                                    control.isTransOn = true;
......
3573 3642
                                        PointC = new StylusPointSet()
3574 3643
                                    };
3575 3644

  
3576
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3577
                                    {
3645
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3646
                                    //{
3578 3647
                                        var polygonControl = (currentControl as CloudControl);
3579 3648
                                        currentControl.CommentID = Save.shortGuid();
3580 3649
                                        currentControl.MarkupInfoID = App.Custom_ViewInfoId;
......
3583 3652

  
3584 3653
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
3585 3654
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
3586
                                    }
3655
                                    //}
3587 3656
                                }
3588 3657
                            }
3589 3658
                        }
......
3592 3661
                        {
3593 3662
                            if (mouseButtonDown == MouseButton.Left)
3594 3663
                            {
3595
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3596
                                {
3664
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3665
                                //{
3597 3666
                                    if (currentControl is ImgControl)
3598 3667
                                    {
3668
                                        if (IsGetoutpoint((currentControl as ImgControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3669
                                        {
3670
                                            return;
3671
                                        }
3672

  
3599 3673
                                        CreateControl();
3600 3674
                                        (currentControl as ImgControl).ApplyOverViewData();
3601 3675

  
......
3627 3701
                                            ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3628 3702
                                        }
3629 3703
                                    }
3630
                                }
3704
                                //}
3631 3705
                            }
3632 3706
                        }
3633 3707
                        break;
......
3635 3709
                        {
3636 3710
                            if (mouseButtonDown == MouseButton.Left)
3637 3711
                            {
3638
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3639
                                {
3712
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3713
                                //{
3640 3714
                                    if (currentControl is DateControl)
3641 3715
                                    {
3716
                                        if (IsGetoutpoint((currentControl as DateControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3717
                                        {
3718
                                            return;
3719
                                        }
3720

  
3642 3721
                                        CreateControl();
3643 3722
                                        (currentControl as DateControl).ApplyOverViewData();
3644 3723
                                        currentControl = null;
......
3666 3745
                                        currentControl.IsNew = true;
3667 3746
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
3668 3747
                                    }
3669
                                }
3748
                                //}
3670 3749
                            }
3671 3750
                        }
3672 3751
                        break;
......
3766 3845
                            {
3767 3846
                                if (currentControl is ArrowTextControl)
3768 3847
                                {
3848
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3849
                                    {
3850
                                        return;
3851
                                    }
3852

  
3769 3853
                                    CreateControl();
3770 3854

  
3771 3855
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
......
3777 3861
                                }
3778 3862
                                else
3779 3863
                                {
3780
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3781
                                    {
3864
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3865
                                    //{
3782 3866
                                        currentControl = new ArrowTextControl();
3783 3867
                                        currentControl.CommentID = Save.shortGuid();
3784 3868
                                        currentControl.IsNew = true;
......
3797 3881

  
3798 3882
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
3799 3883
                                        this.MainAngle.Visibility = Visibility.Visible;
3800
                                    }
3884
                                    //}
3801 3885
                                }
3802 3886
                            }
3803 3887
                        }
......
3808 3892
                            {
3809 3893
                                if (currentControl is ArrowTextControl)
3810 3894
                                {
3895
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3896
                                    {
3897
                                        return;
3898
                                    }
3899

  
3811 3900
                                    CreateControl();
3812 3901
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
3813 3902
                                    currentControl.IsNew = false;
......
3816 3905
                                }
3817 3906
                                else
3818 3907
                                {
3819
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3820
                                    {
3908
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3909
                                    //{
3821 3910
                                        currentControl = new ArrowTextControl();
3822 3911
                                        currentControl.CommentID = Save.shortGuid();
3823 3912
                                        currentControl.IsNew = true;
......
3837 3926

  
3838 3927
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
3839 3928
                                        this.MainAngle.Visibility = Visibility.Visible;
3840
                                    }
3929
                                    //}
3841 3930
                                }
3842 3931
                            }
3843 3932
                        }
......
3848 3937
                            {
3849 3938
                                if (currentControl is ArrowTextControl)
3850 3939
                                {
3940
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3941
                                    {
3942
                                        return;
3943
                                    }
3944

  
3851 3945
                                    CreateControl();
3852 3946
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
3853 3947
                                    currentControl.IsNew = false;
......
3856 3950
                                }
3857 3951
                                else
3858 3952
                                {
3859
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3860
                                    {
3953
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3954
                                    //{
3861 3955
                                        currentControl = new ArrowTextControl()
3862 3956
                                        {
3863 3957
                                            ArrowTextStyle = MarkupToPDF.Controls.Text.ArrowTextControl.ArrowTextStyleSet.Rect
......
3878 3972

  
3879 3973
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
3880 3974
                                        this.MainAngle.Visibility = Visibility.Visible;
3881
                                    }
3975
                                    //}
3882 3976
                                }
3883 3977
                            }
3884 3978
                        }
......
3889 3983
                            {
3890 3984
                                if (currentControl is ArrowTextControl)
3891 3985
                                {
3986
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
3987
                                    {
3988
                                        return;
3989
                                    }
3892 3990
                                    CreateControl();
3893 3991
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
3894 3992
                                    currentControl.IsNew = false;
......
3897 3995
                                }
3898 3996
                                else
3899 3997
                                {
3900
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3901
                                    {
3998
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3999
                                    //{
3902 4000
                                        currentControl = new ArrowTextControl()
3903 4001
                                        {
3904 4002
                                            ArrowTextStyle = MarkupToPDF.Controls.Text.ArrowTextControl.ArrowTextStyleSet.Rect
......
3921 4019

  
3922 4020
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
3923 4021
                                        this.MainAngle.Visibility = Visibility.Visible;
3924
                                    }
4022
                                    //}
3925 4023
                                }
3926 4024
                            }
3927 4025
                        }
......
3932 4030
                            {
3933 4031
                                if (currentControl is ArrowTextControl)
3934 4032
                                {
4033
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4034
                                    {
4035
                                        return;
4036
                                    }
3935 4037
                                    CreateControl();
3936 4038
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
3937 4039
                                    currentControl.IsNew = false;
......
3940 4042
                                }
3941 4043
                                else
3942 4044
                                {
3943
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3944
                                    {
4045
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4046
                                    //{
3945 4047
                                        currentControl = new ArrowTextControl()
3946 4048
                                        {
3947 4049
                                            ArrowTextStyle = MarkupToPDF.Controls.Text.ArrowTextControl.ArrowTextStyleSet.Cloud
......
3961 4063

  
3962 4064
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
3963 4065
                                        this.MainAngle.Visibility = Visibility.Visible;
3964
                                    }
4066
                                    //}
3965 4067
                                }
3966 4068
                            }
3967 4069
                        }
......
3972 4074
                            {
3973 4075
                                if (currentControl is ArrowTextControl)
3974 4076
                                {
4077
                                    if (IsGetoutpoint((currentControl as ArrowTextControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4078
                                    {
4079
                                        return;
4080
                                    }
3975 4081
                                    CreateControl();
3976 4082
                                    (currentControl as ArrowTextControl).Base_TextBox.IsHitTestVisible = false;
3977 4083
                                    currentControl.IsNew = false;
......
3980 4086
                                }
3981 4087
                                else
3982 4088
                                {
3983
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
3984
                                    {
4089
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4090
                                    //{
3985 4091
                                        currentControl = new ArrowTextControl()
3986 4092
                                        {
3987 4093
                                            ArrowTextStyle = MarkupToPDF.Controls.Text.ArrowTextControl.ArrowTextStyleSet.Cloud
......
4004 4110

  
4005 4111
                                        (currentControl as ArrowTextControl).Base_TextBox.Focus();
4006 4112
                                        this.MainAngle.Visibility = Visibility.Visible;
4007
                                    }
4113
                                    //}
4008 4114
                                }
4009 4115
                            }
4010 4116
                        }
......
4026 4132
                                }
4027 4133
                                else
4028 4134
                                {
4135
                                    if (IsGetoutpoint((currentControl as PolygonControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4136
                                    {
4137
                                        return;
4138
                                    }
4139

  
4029 4140
                                    var firstPoint = control.PointSet.First();
4030 4141
                                    control.DashSize = ViewerDataModel.Instance.DashSize;
4031 4142
                                    control.LineSize = ViewerDataModel.Instance.LineSize;
......
4050 4161
                                        //PointC = new StylusPointSet()
4051 4162
                                    };
4052 4163

  
4053
                                    if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4054
                                    {
4164
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4165
                                    //{
4055 4166
                                        var polygonControl = (currentControl as PolygonControl);
4056 4167
                                        currentControl.CommentID = Save.shortGuid();
4057 4168
                                        currentControl.IsNew = true;
......
4060 4171
                                        //currentControl.OnApplyTemplate();
4061 4172
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4062 4173
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4063
                                    }
4174
                                    //}
4064 4175
                                }
4065 4176
                            }
4066 4177
                        }
......
4070 4181
                        {
4071 4182
                            if (mouseButtonDown == MouseButton.Left)
4072 4183
                            {
4073
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4074
                                {
4184
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4185
                                //{
4075 4186
                                    GetUserSign getUser = new GetUserSign();
4076 4187
                                    var _sign = getUser.GetSign(App.ViewInfo.UserID, App.ViewInfo.ProjectNO);
4077 4188

  
......
4088 4199

  
4089 4200
                                    if (currentControl is SignControl)
4090 4201
                                    {
4202
                                        if (IsGetoutpoint((currentControl as SignControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4203
                                        {
4204
                                            return;
4205
                                        }
4206

  
4091 4207
                                        CreateControl();
4092 4208
                                        currentControl = null;
4093 4209
                                        if (Common.ViewerDataModel.Instance.SelectedControl == "Batch")
......
4112 4228
                                        currentControl.MarkupInfoID = App.Custom_ViewInfoId;
4113 4229
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4114 4230
                                    }
4115
                                }
4231
                                //}
4116 4232
                            }
4117 4233
                        }
4118 4234
                        break;
......
4120 4236
                        {
4121 4237
                            if (mouseButtonDown == MouseButton.Left)
4122 4238
                            {
4123
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4124
                                {
4239
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4240
                                //{
4125 4241
                                    if (currentControl is RectangleControl)
4126 4242
                                    {
4243
                                        if (IsGetoutpoint((currentControl as RectangleControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4244
                                        {
4245
                                            return;
4246
                                        }
4247

  
4127 4248
                                        CreateControl();
4128 4249
                                        (currentControl as RectangleControl).ApplyOverViewData();
4129 4250
                                        currentControl = null;
......
4149 4270
                                        (currentControl as RectangleControl).DashSize = ViewerDataModel.Instance.DashSize;
4150 4271
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4151 4272
                                    }
4152
                                }
4273
                                //}
4153 4274
                            }
4154 4275
                        }
4155 4276
                        break;
......
4157 4278
                        {
4158 4279
                            if (mouseButtonDown == MouseButton.Left)
4159 4280
                            {
4160
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4161
                                {
4281
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4282
                                //{
4162 4283
                                    if (currentControl is SymControl)
4163 4284
                                    {
4285
                                        if (IsGetoutpoint((currentControl as SymControl).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4286
                                        {
4287
                                            return;
4288
                                        }
4164 4289
                                        CreateControl();
4165 4290
                                        currentControl = null;
4166 4291
                                        this.cursor = Cursors.Arrow;
......
4179 4304
                                        currentControl.CommentID = Save.shortGuid();
4180 4305
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4181 4306
                                    }
4182
                                }
4307
                                //}
4183 4308
                            }
4184 4309
                        }
4185 4310
                        break;
......
4187 4312
                        {
4188 4313
                            if (mouseButtonDown == MouseButton.Left)
4189 4314
                            {
4190
                                if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4191
                                {
4315
                                //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4316
                                //{
4192 4317
                                    if (currentControl is SymControlN)
4193 4318
                                    {
4319
                                        if (IsGetoutpoint((currentControl as SymControlN).PointSet.Where(data => IsDrawingEnable(data) == true).FirstOrDefault()))
4320
                                        {
4321
                                            return;
4322
                                        }
4323

  
4194 4324
                                        CreateControl();
4195 4325
                                        currentControl = null;
4196 4326
                                        this.cursor = Cursors.Arrow;
......
4209 4339
                                        currentControl.CommentID = Save.shortGuid();
4210 4340
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4211 4341
                                    }
4212
                                }
4342
                                //}
4213 4343
                            }
4214 4344
                        }
4215 4345
                        break;
......
5620 5750
            return res;
5621 5751
        }
5622 5752

  
5753
        /// <summary>
5754
        /// 캔버스에 그릴때 모든 포인트가 캔버스를 벗어 났는지 체크하여 넘겨줌
5755
        /// </summary>
5756
        /// <author>ingu</author>
5757
        /// <date>2018.06.05</date>
5758
        /// <param name="getPoint"></param>
5759
        /// <returns></returns>
5760
        private bool IsGetoutpoint(Point getPoint)
5761
        {
5762
            if (getPoint == new Point())
5763
            {
5764
                ViewerDataModel.Instance.MarkupControls_USER.Remove(currentControl);
5765
                currentControl = null;
5766
                return true;
5767
            }
5768

  
5769
            return false;
5770
        }
5771

  
5623 5772
       
5624 5773
    }
5625 5774
}

내보내기 Unified diff