Don't set a normal cursor for the frame, set the NULL cursor, else

text controls (for example) can get the wrong cursor.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14941 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2002-04-04 21:05:14 +00:00
parent e99e9bc322
commit a570d5b302
3 changed files with 26 additions and 3 deletions

View File

@@ -651,9 +651,7 @@ void cbBarDragPlugin::OnMouseMove( cbMotionEvent& event )
else else
mpCurCursor = mpLayout->mpNECursor; mpCurCursor = mpLayout->mpNECursor;
} }
if ( pPrevCurs != mpCurCursor ) if ( pPrevCurs != mpCurCursor )
mpLayout->GetParentFrame().SetCursor( *mpCurCursor ); mpLayout->GetParentFrame().SetCursor( *mpCurCursor );
} }
@@ -695,7 +693,13 @@ void cbBarDragPlugin::OnLButtonUp( cbLeftUpEvent& event )
mHintRect.width = -1; mHintRect.width = -1;
mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor ); // In Windows, at least, the frame needs to have a null cursor
// else child windows (such as text windows) inherit the cursor
#if 1
mpLayout->GetParentFrame().SetCursor( wxNullCursor );
#else
mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor );
#endif
mpLayout->ReleaseEventsFromPane( event.mpPane ); mpLayout->ReleaseEventsFromPane( event.mpPane );
mpLayout->ReleaseEventsFromPlugin( this ); mpLayout->ReleaseEventsFromPlugin( this );

View File

@@ -279,7 +279,13 @@ void cbPaneDrawPlugin::OnMouseMove( cbMotionEvent& event )
mBarContentHitted = TRUE; mBarContentHitted = TRUE;
// In Windows, at least, the frame needs to have a null cursor
// else child windows (such as text windows) inherit the cursor
#if 1
mpLayout->GetParentFrame().SetCursor( wxNullCursor );
#else
mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor ); mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor );
#endif
} }
// TBD:: fire something like "mouse-over-bar" event // TBD:: fire something like "mouse-over-bar" event
@@ -344,7 +350,13 @@ void cbPaneDrawPlugin::OnMouseMove( cbMotionEvent& event )
mpLayout->ReleaseEventsFromPane( event.mpPane ); mpLayout->ReleaseEventsFromPane( event.mpPane );
mpLayout->ReleaseEventsFromPlugin( this ); mpLayout->ReleaseEventsFromPlugin( this );
// In Windows, at least, the frame needs to have a null cursor
// else child windows (such as text windows) inherit the cursor
#if 1
mpLayout->GetParentFrame().SetCursor( wxNullCursor );
#else
mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor ); mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor );
#endif
mResizeCursorOn = FALSE; mResizeCursorOn = FALSE;
} }
@@ -499,7 +511,13 @@ void cbPaneDrawPlugin::OnLButtonUp( cbLeftUpEvent& event )
mpLayout->ReleaseEventsFromPane( event.mpPane ); mpLayout->ReleaseEventsFromPane( event.mpPane );
mpLayout->ReleaseEventsFromPlugin( this ); mpLayout->ReleaseEventsFromPlugin( this );
// In Windows, at least, the frame needs to have a null cursor
// else child windows (such as text windows) inherit the cursor
#if 1
mpLayout->GetParentFrame().SetCursor( wxNullCursor );
#else
mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor ); mpLayout->GetParentFrame().SetCursor( *mpLayout->mpNormalCursor );
#endif
if ( mRowHandleHitted ) if ( mRowHandleHitted )
{ {

View File

@@ -1035,6 +1035,7 @@ void cbRowLayoutPlugin::OnLayoutRows( cbLayoutRowsEvent& event )
for ( i = 0; i != mpPane->GetRowList().Count(); ++i ) for ( i = 0; i != mpPane->GetRowList().Count(); ++i )
{ {
cbRowInfo& row = *mpPane->GetRowList()[ i ]; cbRowInfo& row = *mpPane->GetRowList()[ i ];
//mpPane->CalcLengthRatios(& row);
// setup "has-handle" flags for rows, which depend on the existance // setup "has-handle" flags for rows, which depend on the existance
// of not-fixed bars in the row // of not-fixed bars in the row