+ // This code is slightly awkward because we need to reset wxRESIZE_BORDER
+ // before calling SetClientSize() below as doing it after setting the
+ // client size would actually change it, at least under MSW, where the
+ // total window size doesn't change and hence, as the borders size changes,
+ // the client size does change.
+ //
+ // So we must call it first but doing it generates a size event and updates
+ // pane.floating_size from inside it so we must also record its original
+ // value before doing it.
+ const bool hasFloatingSize = pane.floating_size != wxDefaultSize;
+ if (pane.IsFixed())
+ {
+ SetWindowStyleFlag(GetWindowStyleFlag() & ~wxRESIZE_BORDER);
+ }
+
+ if ( hasFloatingSize )