Skip to content

Commit

Permalink
Merge branch 'dev' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Oct 14, 2024
2 parents 7626cb5 + 0f3c334 commit 677db0e
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 11 deletions.
10 changes: 5 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@
cmake_minimum_required (VERSION 3.9)

project (Lagrange
VERSION 1.18.2
VERSION 1.18.3
DESCRIPTION "A Beautiful Gemini Client"
LANGUAGES C
)
set (COPYRIGHT_YEAR 2024)
if (IOS)
set (PROJECT_VERSION 1.18)
set (IOS_BUNDLE_VERSION 4)
set (IOS_BUILD_DATE "2024-10-13")
set (IOS_BUNDLE_VERSION 6)
set (IOS_BUILD_DATE "2024-10-14")
endif ()
if (ANDROID)
set (PROJECT_VERSION 1.18)
set (ANDROID_BUILD_VERSION b33) # remember to update Gradle, AndroidManifest.xml
set (ANDROID_BUILD_DATE "2024-10-06")
set (ANDROID_BUILD_VERSION b34) # remember to update Gradle, AndroidManifest.xml
set (ANDROID_BUILD_DATE "2024-10-13")
endif ()

# Load modules from the source tree
Expand Down
2 changes: 1 addition & 1 deletion lib/sealcurses
Submodule sealcurses updated from a28af1 to 700f9b
7 changes: 7 additions & 0 deletions res/about/android-version.gmi
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@
```
# Release notes

## 1.18 (Beta 34)
* Fixed accidental navigation when editing text with the keyboard.
* Fixed handling of the Return key in text fields.
* Misfin: URI format has changed to "misfin:address?message" instead of the previously used "misfin://address". The optional query string ("message") is used as the initial message contents if the upload dialog's text editor is empty.
* Fixed redirection counting (and related warnings) when requesting Titan URIs.
* Updated UI translations.

## 1.18 (Beta 33)
* Fixed crash when uploading data due to uninitialized memory.
* Fixed perpetual load spinner animation when redirected to a Titan URL.
Expand Down
6 changes: 5 additions & 1 deletion res/about/ios-version.gmi
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@
```
# Release notes

## 1.18 (4)
## 1.18 (6)
* ⌘Return can be used to submit input prompts. Return inserts a newline.

## 1.18 (5)
* Fixed accidental navigation when editing text with the keyboard.
* Fixed handling of the Return key in text fields.
* Misfin: URI format has changed to "misfin:address?message" instead of the previously used "misfin://address". The optional query string ("message") is used as the initial message contents if the upload dialog's text editor is empty.
* Fixed redirection counting (and related warnings) when requesting Titan URIs.
* Updated UI translations.
Expand Down
3 changes: 3 additions & 0 deletions res/about/version.gmi
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
```
# Release notes

## 1.18.3
* TUI: Fixed background colors in reduced color modes (less than 256 colors).

## 1.18.2
* Misfin: URI format has changed to "misfin:address?message" instead of the previously used "misfin://address". The optional query string ("message") is used as the initial message contents if the upload dialog's text editor is empty.
* Increased number of concurrent feed subscription requests (now 10, was 4).
Expand Down
12 changes: 8 additions & 4 deletions src/ios.m
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include "app.h"
#include "audio/player.h"
#include "ui/command.h"
#include "ui/keys.h"
#include "ui/window.h"
#include "ui/touch.h"

Expand Down Expand Up @@ -343,10 +344,11 @@ -(void)keyboardOffScreen:(NSNotification *)notification {
setKeyboardHeight_MainWindow(get_MainWindow(), 0);
}

static void sendReturnKeyPress_(void) {
static void sendReturnKeyPress_(int kmods) {
SDL_Event ev = { .type = SDL_KEYDOWN };
ev.key.timestamp = SDL_GetTicks();
ev.key.keysym.sym = SDLK_RETURN;
ev.key.keysym.mod = kmods;
ev.key.state = SDL_PRESSED;
SDL_PushEvent(&ev);
ev.type = SDL_KEYUP;
Expand All @@ -355,7 +357,7 @@ static void sendReturnKeyPress_(void) {
}

- (BOOL)textFieldShouldReturn:(UITextField *)textField {
sendReturnKeyPress_();
sendReturnKeyPress_(0);
return NO;
}

Expand Down Expand Up @@ -387,8 +389,10 @@ - (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRang
- (BOOL)textView:(UITextView *)textView shouldChangeTextInRange:(NSRange)range
replacementText:(NSString *)text {
if ([text isEqualToString:@"\n"]) {
if (!isNewlineAllowed_SystemTextInput_([appState_ systemTextInput])) {
sendReturnKeyPress_();
const iBool isCommandKeyDown = (modState_Keys() & KMOD_PRIMARY) != 0;
if (isCommandKeyDown ||
!isNewlineAllowed_SystemTextInput_([appState_ systemTextInput])) {
sendReturnKeyPress_(isCommandKeyDown ? KMOD_PRIMARY : 0);
return NO;
}
}
Expand Down
5 changes: 5 additions & 0 deletions src/ui/inputwidget.c
Original file line number Diff line number Diff line change
Expand Up @@ -1902,6 +1902,9 @@ static iBool checkLineBreakMods_InputWidget_(const iInputWidget *d, int mods) {
}

static iBool checkAcceptMods_InputWidget_(const iInputWidget *d, int mods) {
if (isMobile_Platform()) {
return mods == KMOD_PRIMARY; /* non-configurable */
}
if (d->inFlags & useReturnKeyBehavior_InputWidgetFlag) {
return mods == acceptKeyMod_ReturnKeyBehavior(prefs_App()->returnKey);
}
Expand Down Expand Up @@ -2679,6 +2682,7 @@ static iBool processEvent_InputWidget_(iInputWidget *d, const SDL_Event *ev) {
return iTrue;
}
}
#endif
if (d->inFlags & enterKeyEnabled_InputWidgetFlag &&
(checkAcceptMods_InputWidget_(d, mods) ||
(~d->inFlags & lineBreaksEnabled_InputWidgetFlag))) {
Expand All @@ -2693,6 +2697,7 @@ static iBool processEvent_InputWidget_(iInputWidget *d, const SDL_Event *ev) {
}
return iTrue;
}
#if !LAGRANGE_USE_SYSTEM_TEXT_INPUT
return iFalse;
#else
/* Native input handles Return key. */
Expand Down

0 comments on commit 677db0e

Please sign in to comment.