apps/piano: refactoring and improvement #302
Reference in New Issue
Block a user
Delete Branch "rewrite-piano"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Refactoring of Piano source code.
Co-authored-by: Doczom mixa.frolov2003@gmail.com
Co-authored-by: qullarwee
What was done:
What remains:
Fix "error finding thread" bugImprove keyboard layout (?)Use another sound player instead of beeper (?)Help needed:
WIP: Piano refacoringto apps/piano: refactoringapps/piano: refactoringto apps/piano: refactoring and improvement@@ -5,0 +3,4 @@; Piano - Toy Piano; Copyright (C) 2019-2025 KolibriOS team;; Contributor ??? - Initial codeI read several pages of the topic and concluded that the program was actually authored by Antonio, with support from Leency. The original code is an example that has nothing in common with the piano developed by Antonio and Leency. Therefore, I propose listing them as the authors:
@@ -5,0 +5,4 @@;; Contributor ??? - Initial code; Contributor Antonio - Refactoring and new functionality; Contributor Burer - Refactoring and Spanish translationYour changes will already be stored using git. Just add the people who helped you as "Co-authored-by" in commit body.
I find this kind of indentation strange... Especially before labels. It seems most programs follow the kernel code style.
@@ -5,3 +4,1 @@tup.rule("echo lang fix " .. ((tup.getconfig("LANG") == "") and "en_US" or tup.getconfig("LANG")) .. " > %o", {"lang.inc"})tup.rule({"piano.asm", extra_inputs = {"lang.inc"}}, FASM .. " %f %o " .. tup.getconfig("KPACK_CMD"), "piano")tup.rule("keymap.asm", FASM .. " %f %o", "piano.map")Why is there no compression via kpack?
For the logic to work, it must be unpacked in “byte per key” format, and unpacking during execution does not make much sense in this case, since it only occupies one sector of the floppy disk anyway.
@@ -0,0 +3,4 @@; Piano - Default Keymap (256 bytes); Copyright (C) 2025 KolibriOS team;; Contributor Burer - Main codeMove co-authors to the commit body
@@ -908,0 +522,4 @@dd 0dd 256dd keymapdb 'piano.map', 0@Burer
It reads from the working directory; therefore, when launched from the menu, a warning appears that the file was not found.
Should be fixed now.
347c29a0d3to2a5f73351b