Skip to content

Commit 65339ba

Browse files
authored
Merge pull request #334 from calband/issues/thumbnail_jumps
Issue #333: Field thumbnail seems to Pop
2 parents 6b2a75c + da770c1 commit 65339ba

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ else ()
114114
target_compile_options (calchart_core PRIVATE -Werror -Wall -Wextra)
115115
endif ()
116116

117-
set_target_properties (calchart_core PROPERTIES CXX_STANDARD 17)
117+
set_target_properties (calchart_core PROPERTIES CXX_STANDARD 20)
118118

119119
target_include_directories (
120120
calchart_core

RELEASE_INSTRUCTIONS.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,9 @@ You'll need to be logged in as Administrator to modify the files.
8282

8383
10. Repeat for Install-CalChart-$CCVER.exe. Click on zip and edit the file details to signify its platform is Windows and set the release_notes for the file.
8484

85-
11. Update https://github.com/calband/calchart/releases
85+
11. Update https://github.com/calband/calchart/releases with Readme version updates.
8686

87-
12. Have a cookie.
87+
12. Update https://github.com/calband/calchart/milestone by closing the shipped milestone and starting the next one.
88+
89+
13. Have a cookie.
8890

src/FieldThumbnailBrowser.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,10 @@ void FieldThumbnailBrowser::HandleMouseDown(wxMouseEvent& event)
227227

228228
void FieldThumbnailBrowser::HandleSizeEvent(wxSizeEvent& event)
229229
{
230-
mLayoutHorizontal = float(event.m_size.x) / float(event.m_size.y) > 1;
230+
auto mode_size = mView->GetShowFieldSize();
231+
auto ratioMode = mode_size.y ? mode_size.x / float(mode_size.y) : 0;
232+
auto ratioSize = event.m_size.y ? event.m_size.x / float(event.m_size.y) : 0;
233+
234+
mLayoutHorizontal = ratioSize > ratioMode;
231235
OnUpdate();
232236
}

0 commit comments

Comments
 (0)