// Licence: wxWindows license
/////////////////////////////////////////////////////////////////////////////
// Licence: wxWindows license
/////////////////////////////////////////////////////////////////////////////
{
"............XX....XX............",
"............XX....XX............",
{
"............XX....XX............",
"............XX....XX............",
{
"................X...............",
"...............XXX..............",
{
"................X...............",
"...............XXX..............",
"...............XXX..............",
"................X..............."
};
"...............XXX..............",
"................X..............."
};
mGrayPen ( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mBlackPen ( wxColour( 0, 0, 0), 1, wxSOLID ),
mBorderPen( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mGrayPen ( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mBlackPen ( wxColour( 0, 0, 0), 1, wxSOLID ),
mBorderPen( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mNullPen( wxColour(0,0,0), 1, wxTRANSPARENT ),
mpPaneInFocus( NULL ),
mNullPen( wxColour(0,0,0), 1, wxTRANSPARENT ),
mpPaneInFocus( NULL ),
- mClientWndRefreshPending( FALSE ),
- mRecalcPending( TRUE ),
- mCheckFocusWhenIdle( FALSE )
+ mClientWndRefreshPending( false ),
+ mRecalcPending( true ),
+ mCheckFocusWhenIdle( false )
mGrayPen ( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mBlackPen ( wxColour( 0, 0, 0), 1, wxSOLID ),
mBorderPen( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mGrayPen ( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mBlackPen ( wxColour( 0, 0, 0), 1, wxSOLID ),
mBorderPen( wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE), 1, wxSOLID ),
mNullPen( wxColour(0,0,0), 1, wxTRANSPARENT ),
mpPaneInFocus( NULL ),
mpLRUPane ( NULL ),
mNullPen( wxColour(0,0,0), 1, wxTRANSPARENT ),
mpPaneInFocus( NULL ),
mpLRUPane ( NULL ),
-
- mClientWndRefreshPending( FALSE ),
- mRecalcPending( TRUE ),
- mCheckFocusWhenIdle( FALSE ),
-
+
+ mClientWndRefreshPending( false ),
+ mRecalcPending( true ),
+ mCheckFocusWhenIdle( false ),
+
-#ifdef __WXMSW__
-#if 0
-
- if ( pChild->GetParent() )
- {
- bool success = pChild->GetParent()->GetChildren().DeleteObject( pChild );
-
- wxASSERT( success ); // DBG::
- }
-
- ::SetParent( (HWND)pChild->m_hWnd, (HWND)pNewParent->m_hWnd );
-
- pNewParent->GetChildren().Append( pChild );
-
- pChild->SetParent( pNewParent );
-#endif
+#if defined(__WXMSW__) || defined(__WXGTK20__) || defined(__WXMAC__)
- wxMessageBox( "Sorry, docking is not supported for ports other than MSW and wxGTK" );
+ wxUnusedVar(pChild);
+ wxUnusedVar(pNewParent);
+ wxMessageBox( _("Sorry, docking is not supported for ports other than wxMSW, wxMac and wxGTK") );
// FIXME FIXME:: the recalculation below may be a *huge* performance
// hit, it could be eliminated though...
// FIXME FIXME:: the recalculation below may be a *huge* performance
// hit, it could be eliminated though...
- pMiniFrm->Create( &GetParentFrame(), -1, pBar->mName,
+ pMiniFrm->Create( &GetParentFrame(), wxID_ANY, pBar->mName,
if ( mAllBars[i] == pBarInfo )
{
#if wxCHECK_VERSION(2,3,2)
if ( mAllBars[i] == pBarInfo )
{
#if wxCHECK_VERSION(2,3,2)
mPanes[FL_ALIGN_TOP ]->mBoundsInParent.height;
mClntWndBounds.width = mPanes[FL_ALIGN_RIGHT]->mBoundsInParent.x -
mPanes[FL_ALIGN_TOP ]->mBoundsInParent.height;
mClntWndBounds.width = mPanes[FL_ALIGN_RIGHT]->mBoundsInParent.x -
mClntWndBounds.width, mClntWndBounds.height, 0 );
if ( !mpFrameClient->IsShown() )
mClntWndBounds.width, mClntWndBounds.height, 0 );
if ( !mpFrameClient->IsShown() )
size_t i;
for ( i = 0; i != mAllBars.Count(); ++i )
if ( mAllBars[i]->mpBarWnd && mAllBars[i]->mState != wxCBAR_FLOATING )
size_t i;
for ( i = 0; i != mAllBars.Count(); ++i )
if ( mAllBars[i]->mpBarWnd && mAllBars[i]->mState != wxCBAR_FLOATING )
// NOTE:: the SetEvtHandlerEnabled() method is not used
// here, since it is assumed that unhooking layout
// from window may result destroying of the layout itself
// NOTE:: the SetEvtHandlerEnabled() method is not used
// here, since it is assumed that unhooking layout
// from window may result destroying of the layout itself
- //
- // BUG BUG BUG (wx):: this would not be a problem if
- // wxEvtHandler's destructor checked if
- // this handler is currently the top-most
- // handler of some window, and additionally
+ //
+ // BUG BUG BUG (wx):: this would not be a problem if
+ // wxEvtHandler's destructor checked if
+ // this handler is currently the top-most
+ // handler of some window, and additionally
set_cursor_bits( _gHorizCursorImg, bits, 32, 16 );
mpHorizCursor = new wxCursor( bits, 32, 16 );
set_cursor_bits( _gHorizCursorImg, bits, 32, 16 );
mpHorizCursor = new wxCursor( bits, 32, 16 );
-
-void wxFrameLayout::OnKillFocus( wxFocusEvent& event )
-{
- //wxMessageBox( "wxFrameLayoutGot Kill Focus!" );
- //ShowFloatedWindows( FALSE );
-}
-
-void wxFrameLayout::OnSetFocus( wxFocusEvent& event )
-{
- //ShowFloatedWindows( TRUE );
-}
-
-void wxFrameLayout::OnActivate( wxActivateEvent& event )
-{
-#if 0
- if ( event.GetActive() == FALSE )
- {
- wxWindow* focus = wxWindow::FindFocus();
-
- if ( !focus || focus == &GetParentFrame() )
- {
- mCheckFocusWhenIdle = TRUE;
-
- if ( !focus )
-
- wxMessageBox("Deactivated!" );
-
- }
- }
-#endif
-}
-
void wxFrameLayout::GetPaneProperties( cbCommonPaneProperties& props, int alignment )
{
props = mPanes[alignment]->mProps;
void wxFrameLayout::GetPaneProperties( cbCommonPaneProperties& props, int alignment )
{
props = mPanes[alignment]->mProps;
- if ( event.m_eventType != cbEVT_PL_LEFT_DOWN &&
- event.m_eventType != cbEVT_PL_LEFT_UP &&
- event.m_eventType != cbEVT_PL_RIGHT_DOWN &&
- event.m_eventType != cbEVT_PL_RIGHT_UP &&
- event.m_eventType != cbEVT_PL_MOTION )
- isInputEvt = FALSE;
+ if ( event.GetEventType() != cbEVT_PL_LEFT_DOWN &&
+ event.GetEventType() != cbEVT_PL_LEFT_UP &&
+ event.GetEventType() != cbEVT_PL_RIGHT_DOWN &&
+ event.GetEventType() != cbEVT_PL_RIGHT_UP &&
+ event.GetEventType() != cbEVT_PL_MOTION )
+ isInputEvt = false;
case cbEVT_PL_RIGHT_DOWN : break;
case cbEVT_PL_RIGHT_UP : break;
case cbEVT_PL_MOTION : break;
case cbEVT_PL_RIGHT_DOWN : break;
case cbEVT_PL_RIGHT_UP : break;
case cbEVT_PL_MOTION : break;
: mPrevBounds( -1,-1,0,0 ),
: mPrevBounds( -1,-1,0,0 ),
size_t i;
for ( i = 0; i != MAX_BAR_STATES; ++i )
mBounds[i] = wxRect( -1,-1,-1,-1 );
size_t i;
for ( i = 0; i != MAX_BAR_STATES; ++i )
mBounds[i] = wxRect( -1,-1,-1,-1 );
mSizes[wxCBAR_DOCKED_VERTICALLY ].y = y;
mSizes[wxCBAR_FLOATING ].x = x;
mSizes[wxCBAR_FLOATING ].y = y;
mSizes[wxCBAR_DOCKED_VERTICALLY ].y = y;
mSizes[wxCBAR_FLOATING ].x = x;
mSizes[wxCBAR_FLOATING ].y = y;
size_t i;
for ( i = 0; i != MAX_BAR_STATES; ++i )
mBounds[i] = wxRect( -1,-1,-1,-1 );
size_t i;
for ( i = 0; i != MAX_BAR_STATES; ++i )
mBounds[i] = wxRect( -1,-1,-1,-1 );
- : mRealTimeUpdatesOn ( TRUE ),
- mOutOfPaneDragOn ( TRUE ),
- mExactDockPredictionOn( FALSE ),
- mNonDestructFrictionOn( FALSE ),
- mShow3DPaneBorderOn ( TRUE ),
- mBarFloatingOn ( FALSE ),
- mRowProportionsOn ( FALSE ),
- mColProportionsOn ( TRUE ),
- mBarCollapseIconsOn ( FALSE ),
- mBarDragHintsOn ( FALSE ),
+ : mRealTimeUpdatesOn ( true ),
+ mOutOfPaneDragOn ( true ),
+ mExactDockPredictionOn( false ),
+ mNonDestructFrictionOn( false ),
+ mShow3DPaneBorderOn ( true ),
+ mBarFloatingOn ( false ),
+ mRowProportionsOn ( false ),
+ mColProportionsOn ( true ),
+ mBarCollapseIconsOn ( false ),
+ mBarDragHintsOn ( false ),
mColProportionsOn = props.mColProportionsOn;
mBarCollapseIconsOn = props.mBarCollapseIconsOn;
mBarDragHintsOn = props.mBarDragHintsOn;
mColProportionsOn = props.mColProportionsOn;
mBarCollapseIconsOn = props.mBarCollapseIconsOn;
mBarDragHintsOn = props.mBarDragHintsOn;
// be known, while inserting bars initially
mPaneHeight( 32768 ),
mAlignment ( alignment ),
mpLayout ( pPanel ),
// be known, while inserting bars initially
mPaneHeight( 32768 ),
mAlignment ( alignment ),
mpLayout ( pPanel ),
// NOTE:: control bar infromation structures are cleaned-up
// in wxFrameLayout's destructor, using global control-bar list
}
// NOTE:: control bar infromation structures are cleaned-up
// in wxFrameLayout's destructor, using global control-bar list
}
PaintBarDecorations( pRow->mBars[i], dc );
// then handles if present
PaintBarDecorations( pRow->mBars[i], dc );
// then handles if present
mpStoredRow == pBar->mpRow;
cbRemoveBarEvent evt( pBar, this );
mpStoredRow == pBar->mpRow;
cbRemoveBarEvent evt( pBar, this );
void cbDockPane::SyncRowFlags( cbRowInfo* pRow )
{
// setup mHasOnlyFixedBars flag for the row information
void cbDockPane::SyncRowFlags( cbRowInfo* pRow )
{
// setup mHasOnlyFixedBars flag for the row information
void cbDockPane::PaneToFrame( int* x, int* y )
{
if ( mAlignment == FL_ALIGN_TOP ||
void cbDockPane::PaneToFrame( int* x, int* y )
{
if ( mAlignment == FL_ALIGN_TOP ||
void cbDockPane::RecalcRowLayout( cbRowInfo* pRow )
{
cbLayoutRowEvent evt( pRow, this );
void cbDockPane::RecalcRowLayout( cbRowInfo* pRow )
{
cbLayoutRowEvent evt( pRow, this );
pBarInfo->mLenRatio = 0.0;
// set preferred bar dimensions, according to the state in which
pBarInfo->mLenRatio = 0.0;
// set preferred bar dimensions, according to the state in which
-inline bool cbDockPane::HasPoint( const wxPoint& pos, int x, int y,
+inline bool cbDockPane::HasPoint( const wxPoint& pos, int x, int y,
- if ( HasPoint( pos, 0, row.mRowY + row.mRowHeight - mProps.mResizeHandleSize,
+ if ( HasPoint( pos, 0, row.mRowY + row.mRowHeight - mProps.mResizeHandleSize,
row.mRowWidth, mProps.mResizeHandleSize ) )
return CB_LOWER_ROW_HANDLE_HITTED;
row.mRowWidth, mProps.mResizeHandleSize ) )
return CB_LOWER_ROW_HANDLE_HITTED;
{
if ( HasPoint( pos, bounds.x + bounds.width - mProps.mResizeHandleSize, bounds.y,
mProps.mResizeHandleSize, bounds.height ) )
{
if ( HasPoint( pos, bounds.x + bounds.width - mProps.mResizeHandleSize, bounds.y,
mProps.mResizeHandleSize, bounds.height ) )
bool forUpperHandle )
{
cbResizeRowEvent evt( pRow, ofs, forUpperHandle, this );
bool forUpperHandle )
{
cbResizeRowEvent evt( pRow, ofs, forUpperHandle, this );
if ( bounds.width + ofs < mProps.mMinCBarDim.x )
{
bounds.x = bounds.x + bounds.width + ofs - mProps.mMinCBarDim.x;
if ( bounds.width + ofs < mProps.mMinCBarDim.x )
{
bounds.x = bounds.x + bounds.width + ofs - mProps.mMinCBarDim.x;
dc.DrawLine( x,y, right, y );
}
dc.DrawLine( x,y, right, y );
}
- dc.DrawLine( x,y, right, ++y );
+ dc.DrawLine( x,y, right, y );
- dc.DrawLine( x,y, right, ++y );
+ dc.DrawLine( x,y, right, y );