Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port from GTK 2 to GTK 3 #220

Merged
merged 5 commits into from
Mar 27, 2023
Merged

Port from GTK 2 to GTK 3 #220

merged 5 commits into from
Mar 27, 2023

Conversation

xyproto
Copy link
Contributor

@xyproto xyproto commented Dec 22, 2020

Hi,

I'm maintaining the Neko package for Arch Linux.

GTK 2 has reached its end of life: https://blog.gtk.org/2020/12/16/gtk-4-0/

This patch changes the Neko sources from depending on GTK 2 to depending on GTK 3.

The only code change is calling gdk_threads_add_timeout instead of calling gtk_timeout_add.

The changes were tested with this simple Neko program, and appears to be working:

var ui_loop = $loader.loadprim("ui@ui_loop", 0)
var ui_stop_loop = $loader.loadprim("ui@ui_stop_loop", 0)
var ui_is_main = $loader.loadprim("ui@ui_is_main", 0)
var ui_sync = $loader.loadprim("ui@ui_sync", 1)

ui_sync(function() {
  $print("UI is main? ", ui_is_main(), "\n")
  $print("Stopping UI loop\n")
  ui_stop_loop()
})

$print("Starting UI loop\n")
ui_loop()
$print("DONE\n")

@xyproto
Copy link
Contributor Author

xyproto commented Dec 22, 2020

The Azure pipeline error is unrelated to this pull request:

-- Using src='https://downloads.mariadb.org/f/connector-c-3.0.9/mariadb-connector-c-3.0.9-src.tar.gz'
CMake Error at MariaDBConnector-stamp/download-MariaDBConnector.cmake:170 (message):
  Each download failed!

    error: downloading 'https://downloads.mariadb.org/f/connector-c-3.0.9/mariadb-connector-c-3.0.9-src.tar.gz' failed
          status_code: 22
          status_string: "HTTP response code said error"
          log:

@skial skial mentioned this pull request Dec 23, 2020
1 task
@Simn
Copy link
Member

Simn commented Mar 27, 2023

@tobil4sk Could you check if we want to merge this (after resolving conflicts)? It makes sense to not depend on EOL versions if it can be helped.

Earthfile Show resolved Hide resolved
@tobil4sk
Copy link
Member

@tobil4sk Could you check if we want to merge this (after resolving conflicts)? It makes sense to not depend on EOL versions if it can be helped.

Yes, we definitely want to merge this. The sample file from above still runs fine.

@xyproto Thanks for resolving all conflicts, looks good to me now.

@xyproto
Copy link
Contributor Author

xyproto commented Mar 27, 2023

Thanks for reviewing, and for maintaining Neko!

@Simn Simn merged commit c08639c into HaxeFoundation:master Mar 27, 2023
@xyproto xyproto deleted the gtk3 branch March 28, 2023 07:43
andyli pushed a commit that referenced this pull request Jul 4, 2023
* Port from GTK 2 to GTK 3

* Update the Earthfile

* Add missing line from README

* Update the Earthfile
# Conflicts:
#	CMakeLists.txt
#	README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants