MCPcopy Create free account
hub / github.com/SpartanJ/eepp / initImageView

Method initImageView

src/tools/ecode/ecode.cpp:3976–3990  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3974}
3975
3976void App::initImageView() {
3977 const auto hideImagePreview = [this] {
3978 mImageLayout->findByType<UIImageViewer>( UI_TYPE_IMAGE_VIEWER )->reset();
3979 mImageLayout->setEnabled( false )->setVisible( false );
3980 if ( mSplitter->getCurWidget() )
3981 mSplitter->getCurWidget()->setFocus();
3982 };
3983 mImageLayout->find( "image_close" )->on( Event::MouseClick, [hideImagePreview]( auto ) {
3984 hideImagePreview();
3985 } );
3986 mImageLayout->on( Event::KeyDown, [hideImagePreview]( const Event* event ) {
3987 if ( event->asKeyEvent()->getKeyCode() == KEY_ESCAPE )
3988 hideImagePreview();
3989 } );
3990}
3991
3992bool App::isFileVisibleInTreeView( const std::string& filePath ) {
3993 if ( !appInstance || mDestroyingApp || !mFileSystemMatcher ||

Callers

nothing calls this directly

Calls 8

getCurWidgetMethod · 0.80
asKeyEventMethod · 0.80
resetMethod · 0.45
setVisibleMethod · 0.45
setEnabledMethod · 0.45
setFocusMethod · 0.45
onMethod · 0.45
findMethod · 0.45

Tested by

no test coverage detected