mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-05-29 17:46:29 +03:00
Fixed a minor bug on cUISkinComplex that prevented to render correctly some skins.
Changed the common dialog listbox scroll sensibility. My lazyness it's beyond limits, and i didn't code a sh*t, and now my plans for this week are f*ck*d.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#include "cuicommondialog.hpp"
|
||||
#include "cuimanager.hpp"
|
||||
#include "cuilistboxitem.hpp"
|
||||
#include "cuithememanager.hpp"
|
||||
|
||||
namespace EE { namespace UI {
|
||||
|
||||
@@ -86,6 +87,13 @@ cUICommonDialog::cUICommonDialog( const cUICommonDialog::CreateParams& Params )
|
||||
LBParams.Size = eeSize( Container()->Size().Width() - 12, Container()->Size().Height() - 92 );
|
||||
LBParams.Flags = UI_AUTO_PADDING | UI_ANCHOR_RIGHT | UI_ANCHOR_LEFT | UI_ANCHOR_TOP | UI_ANCHOR_BOTTOM | UI_CLIP_ENABLE;
|
||||
LBParams.FontSelectedColor = eeColorA( 255, 255, 255, 255 );
|
||||
|
||||
if ( NULL != cUIThemeManager::instance()->DefaultTheme() ) {
|
||||
cUITheme * Theme = cUIThemeManager::instance()->DefaultTheme();
|
||||
|
||||
LBParams.FontSelectedColor = Theme->FontSelectedColor();
|
||||
}
|
||||
|
||||
mList = eeNew( cUIListBox, ( LBParams ) );
|
||||
mList->Visible( true );
|
||||
mList->Enabled( true );
|
||||
@@ -192,6 +200,10 @@ void cUICommonDialog::RefreshFolder() {
|
||||
}
|
||||
|
||||
mList->AddListBoxItems( files );
|
||||
|
||||
if ( NULL != mList->VerticalScrollBar() ) {
|
||||
mList->VerticalScrollBar()->ClickStep( 1.f / ( ( mList->Count() * mList->RowHeight() ) / (eeFloat)mList->Size().Height() ) );
|
||||
}
|
||||
}
|
||||
|
||||
void cUICommonDialog::OpenSaveClick() {
|
||||
|
||||
@@ -126,6 +126,9 @@ void cUISkinComplex::Draw( const eeFloat& X, const eeFloat& Y, const eeFloat& Wi
|
||||
tShape->Draw( X + dls.Width(), Y + Height - tShape->RealSize().Height(), mTempColor );
|
||||
|
||||
tShape->ResetDestWidthAndHeight();
|
||||
|
||||
if ( dls.Height() == 0 && drs.Height() == 0 )
|
||||
dls.Height( tShape->RealSize().Height() );
|
||||
}
|
||||
|
||||
tShape = mShape[ State ][ Center ];
|
||||
|
||||
Reference in New Issue
Block a user