Ver código fonte

Dragging tabs now drags them from the center and not from the left edge

Marko Pintera 12 anos atrás
pai
commit
8c7cb2c327

+ 1 - 1
CamelotClient/Source/BsGUITabbedTitleBar.cpp

@@ -184,7 +184,7 @@ namespace BansheeEditor
 				mDraggedBtn = mTabButtons[uniqueIdxToSeqIdx(mTempDraggedTabIdx)];
 				mDraggedBtn = mTabButtons[uniqueIdxToSeqIdx(mTempDraggedTabIdx)];
 				mDraggedBtn->_setDraggedState(true);
 				mDraggedBtn->_setDraggedState(true);
 
 
-				mInitialDragOffset = Math::roundToInt(mDraggedBtn->_getWidth() * 0.5f);
+				mInitialDragOffset = Math::roundToInt(mDraggedBtn->_getOptimalSize().x * 0.5f);
 				mDragInProgress = true;
 				mDragInProgress = true;
 			}
 			}
 
 

+ 0 - 1
EditorWindowDock.txt

@@ -1,7 +1,6 @@
 TODO:
 TODO:
  - When dragging a tab and then releasing the drag over another tab, that tab becomes active
  - When dragging a tab and then releasing the drag over another tab, that tab becomes active
  - When dragging a temp tab I drag it from its left side while it would be better to drag it from center
  - When dragging a temp tab I drag it from its left side while it would be better to drag it from center
- - Vector subscript out of range issue I'm not sure how to reproduce
  - Clip tabs so that they don't overlap min/close buttons
  - Clip tabs so that they don't overlap min/close buttons
  - (Unrelated) Can't click and drag a scroll handle
  - (Unrelated) Can't click and drag a scroll handle