개정판 7211e0c2
issue #000: symbol(svg, img) 기존 place 방식으로 변경
Change-Id: I203093a09129289cd338e85a9365d56790ff98c6
KCOM/Views/MainMenu.xaml.cs | ||
---|---|---|
1060 | 1060 |
{ |
1061 | 1061 |
//Control_Init(e.Source); |
1062 | 1062 |
} |
1063 |
private Window _dragdropWindow = null; |
|
1063 |
//private Window _dragdropWindow = null;
|
|
1064 | 1064 |
|
1065 | 1065 |
[DllImport("user32.dll")] |
1066 | 1066 |
[return: MarshalAs(UnmanagedType.Bool)] |
... | ... | |
1072 | 1072 |
public Int32 X; |
1073 | 1073 |
public Int32 Y; |
1074 | 1074 |
}; |
1075 |
public string symbol_id = null; |
|
1076 |
public long symbol_group_id; |
|
1077 |
public int symbol_SelectedIndex; |
|
1078 |
public ImageSource symbol_img; |
|
1079 |
public string symbol_Data = null; |
|
1080 |
public void symboldata(string id, long group_id, int SelectedIndex, string Data_, ImageSource img) |
|
1081 |
{ |
|
1082 |
if (this._dragdropWindow != null) |
|
1083 |
{ |
|
1084 |
this._dragdropWindow.Close(); |
|
1085 |
this._dragdropWindow = null; |
|
1086 |
} |
|
1087 |
|
|
1088 |
symbol_id = id; |
|
1089 |
symbol_group_id = group_id; |
|
1090 |
symbol_SelectedIndex = SelectedIndex; |
|
1091 |
symbol_Data = Data_; |
|
1092 |
symbol_img = img; |
|
1093 |
|
|
1094 |
|
|
1095 |
CreateDragDropWindow2(img); |
|
1096 |
} |
|
1075 |
/* |
|
1076 |
public string symbol_id = null; |
|
1077 |
public long symbol_group_id; |
|
1078 |
public int symbol_SelectedIndex; |
|
1079 |
public ImageSource symbol_img; |
|
1080 |
public string symbol_Data = null; |
|
1081 |
public void symboldata(string id, long group_id, int SelectedIndex, string Data_, ImageSource img) |
|
1082 |
{ |
|
1083 |
PlaceImageSymbol(symbol_id, symbol_group_id, symbol_SelectedIndex, new Point(zoomAndPanCanvas.ActualWidth / 2, |
|
1084 |
zoomAndPanCanvas.ActualHeight / 2)); |
|
1085 |
|
|
1086 |
|
|
1087 |
if (this._dragdropWindow != null) |
|
1088 |
{ |
|
1089 |
this._dragdropWindow.Close(); |
|
1090 |
this._dragdropWindow = null; |
|
1091 |
} |
|
1092 |
|
|
1093 |
symbol_id = id; |
|
1094 |
symbol_group_id = group_id; |
|
1095 |
symbol_SelectedIndex = SelectedIndex; |
|
1096 |
symbol_Data = Data_; |
|
1097 |
symbol_img = img; |
|
1098 |
|
|
1099 |
|
|
1100 |
CreateDragDropWindow2(img); |
|
1101 |
|
|
1102 |
} |
|
1097 | 1103 |
|
1098 |
private void CreateDragDropWindow2(ImageSource image)
|
|
1104 |
private void CreateDragDropWindow2(ImageSource image) |
|
1099 | 1105 |
{ |
1100 | 1106 |
this._dragdropWindow = new Window(); |
1101 | 1107 |
_dragdropWindow.Cursor = new Cursor(MainWindow.CursorChange().StreamSource); |
... | ... | |
1123 | 1129 |
this._dragdropWindow.Top = w32Mouse.Y - (image.Height / 2); |
1124 | 1130 |
this._dragdropWindow.Show(); |
1125 | 1131 |
} |
1126 |
|
|
1132 |
*/ |
|
1127 | 1133 |
private void zoomAndPanControl_MouseMove(object sender, MouseEventArgs e) |
1128 | 1134 |
{ |
1129 | 1135 |
if (Common.ViewerDataModel.Instance.SelectedControl == "Batch") |
... | ... | |
1523 | 1529 |
e.Handled = true; |
1524 | 1530 |
} |
1525 | 1531 |
} |
1532 |
/* |
|
1526 | 1533 |
else if ((e.LeftButton == MouseButtonState.Pressed) && mouseHandlingMode == MouseHandlingMode.DragSymbol) |
1527 | 1534 |
{ //symbol |
1528 | 1535 |
if(_dragdropWindow != null) |
... | ... | |
1534 | 1541 |
this._dragdropWindow.Top = w32Mouse.Y - (symbol_img.Height / 2); |
1535 | 1542 |
} |
1536 | 1543 |
} |
1544 |
*/ |
|
1537 | 1545 |
else if ((e.LeftButton == MouseButtonState.Released) && (e.MiddleButton == MouseButtonState.Released) && |
1538 | 1546 |
(e.RightButton == MouseButtonState.Released) && ViewerDataModel.Instance.MarkupControls_USER.Count > 0) |
1539 | 1547 |
{ |
... | ... | |
2105 | 2113 |
{ |
2106 | 2114 |
(e.OriginalSource as System.Windows.Controls.Image).Focus(); |
2107 | 2115 |
} |
2108 |
|
|
2116 |
/* |
|
2109 | 2117 |
if (mouseHandlingMode == MouseHandlingMode.DragSymbol && e.LeftButton == MouseButtonState.Pressed) |
2110 | 2118 |
{ |
2111 | 2119 |
canvasZoomPanningMouseDownPoint = e.GetPosition(zoomAndPanCanvas); |
... | ... | |
2124 | 2132 |
symbol_id = null; |
2125 | 2133 |
} |
2126 | 2134 |
} |
2135 |
*/ |
|
2127 | 2136 |
|
2128 | 2137 |
if (e.LeftButton == MouseButtonState.Pressed) |
2129 | 2138 |
{ |
내보내기 Unified diff