Skip to content

Instantly share code, notes, and snippets.

@jonmcclung
jonmcclung / Toast.qml
Last active July 19, 2024 14:10
Toast in QML. This implementation creates black toast with white text that appears at the bottom of the screen. It also supports adding multiple toast at a time using ToastManager with the newest toast at the bottom.
import QtQuick 2.0
/**
* adapted from StackOverflow:
* http://stackoverflow.com/questions/26879266/make-toast-in-android-by-qml
*/
/**
* @brief An Android-like timed message text in a box that self-destroys when finished if desired
*/
@JPGygax68
JPGygax68 / consume-ffmpeg-libs.cmake
Last active July 12, 2023 09:35
#CMake: how to add the #FFmpeg libraries to a target
# Detect architecture
if (CMAKE_SIZEOF_VOID_P MATCHES 8)
set( PROJECT_ARCH "x86_64" )
else(CMAKE_SIZEOF_VOID_P MATCHES 8)
set( PROJECT_ARCH "x86" )
endif(CMAKE_SIZEOF_VOID_P MATCHES 8)
# FFmpeg