All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Cooper Jr., Franklin" <fcooper@ti.com>
To: "Stiffler, Jacob" <j-stiffler@ti.com>,
	"meta-arago@arago-project.org" <meta-arago@arago-project.org>
Subject: Re: [PATCH] matrix-gui: Clear background when starting and	stopping matrix.
Date: Tue, 17 Mar 2015 15:43:23 +0000	[thread overview]
Message-ID: <8F29D6B095ED194EA1980491A5E029710C848EA5@DFLE08.ent.ti.com> (raw)
In-Reply-To: <1426603161-11566-1-git-send-email-j-stiffler@ti.com>

Overall by modifying this init script your making changes that are only needed for Qt 5 eglfs users. Users can use Qt 4 and Qt 5 Wayland which this patch may cause problems for.

Honestly your probably better off duplicating this init script and making a Qt 5 eglfs variant since there seems to be a significant amount of tweaks. Then select which init you want based on if Qt 5 is being used and if Wayland is being used.


Additional comments below.
> -----Original Message-----
> From: meta-arago-bounces@arago-project.org [mailto:meta-arago-
> bounces@arago-project.org] On Behalf Of Stiffler, Jacob
> Sent: Tuesday, March 17, 2015 9:39 AM
> To: meta-arago@arago-project.org
> Subject: [meta-arago] [PATCH] matrix-gui: Clear background when starting
> and stopping matrix.
> 
> * Clearing the background is done by calling refresh_screen with the
>   "background-black" argument.
> * Always switch virtual terminals so that command prompt will be visible
>   upon exiting matrix.
> * Disable blinking cursor while matrix is running, re-enable when stopping
>   matrix.
>     - When using qt over eglfs, the blinking cursor will show through the
>       gui.
> 
> Signed-off-by: Jacob Stiffler <j-stiffler@ti.com>
> ---
>  .../recipes-core/matrix/matrix-gui/init            |   10 +++++++++-
>  .../recipes-core/matrix/matrix-gui_2.0.bb          |    4 +---
>  2 files changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/meta-arago-extras/recipes-core/matrix/matrix-gui/init b/meta-
> arago-extras/recipes-core/matrix/matrix-gui/init
> index 3ec0a55..9f0507f 100644
> --- a/meta-arago-extras/recipes-core/matrix/matrix-gui/init
> +++ b/meta-arago-extras/recipes-core/matrix/matrix-gui/init
> @@ -16,7 +16,7 @@ test -x "$matrixgui" || exit 0
> 
>  case "$1" in
>    start)
> -    __SWITCH_FOREGROUND_VT__
> +    chvt 4
[Franklin] I don't understand why you're getting rid of __SWITCH_FOREGROUND_VT__ when its sole purpose is to give you the flexibility. Your hard coding rather than using the variable which can end up causing problems for Wayland. Just use the variable.
> 
>      #Clear out the the tmp and lock directory
>      cd __MATRIX_WEB_DIR__
> @@ -34,6 +34,9 @@ case "$1" in
>        fi
>      fi
> 
> +    echo 0 > /sys/class/graphics/fbcon/cursor_blink
> +    refresh_screen "background-black"
[Franklin] This isn't needed. Matrix GUI gets displayed full screen so there is no need for refresh screen.
> +
>      echo -n "Starting Matrix GUI application"
>      start-stop-daemon --start --quiet --background -m --pidfile $PIDFILE --exec
> $matrixgui -- $GUI_OPTS
>      echo "."
> @@ -42,6 +45,11 @@ case "$1" in
>    stop)
>      echo -n "Stopping Matrix GUI application"
>      start-stop-daemon --stop --quiet --pidfile $PIDFILE
> +
> +    refresh_screen "background-black"
> +    echo 1 > /sys/class/graphics/fbcon/cursor_blink
> +    chvt 1
> +
>      echo "."
>      ;;
>    *)
> diff --git a/meta-arago-extras/recipes-core/matrix/matrix-gui_2.0.bb
> b/meta-arago-extras/recipes-core/matrix/matrix-gui_2.0.bb
> index 1b61ff1..b4161ff 100644
> --- a/meta-arago-extras/recipes-core/matrix/matrix-gui_2.0.bb
> +++ b/meta-arago-extras/recipes-core/matrix/matrix-gui_2.0.bb
> @@ -6,7 +6,7 @@ LIC_FILES_CHKSUM =
> "file://LICENSE;md5=a886c9ef769b2d8271115d2502512e5d"
> 
>  SECTION = "multimedia"
> 
> -PR = "r21"
> +PR = "r22"
> 
>  INITSCRIPT_NAME = "matrix-gui-2.0"
>  INITSCRIPT_PARAMS = "defaults 97"
> @@ -27,7 +27,6 @@ require matrix-gui-paths.inc  S = "${WORKDIR}/git"
> 
>  MATRIX_FLAGS = "${@base_conditional('QT_PROVIDER','qt5','','-qws',d)}"
> -SWITCH_FOREGROUND_VT =
> "${@base_conditional('QT_PROVIDER','qt5','','chvt 4',d)}"
>  do_install(){
>  	install -d ${D}${MATRIX_BASE_DIR}
>  	install -d ${D}${MATRIX_WEB_DIR}
> @@ -39,7 +38,6 @@ do_install(){
>  	# Set the proper path in the init script
>  	sed -i -e s=__MATRIX_WEB_DIR__=${MATRIX_WEB_DIR}=
> ${WORKDIR}/init
>  	sed -i -e "s/__MATRIX_FLAGS__/\"${MATRIX_FLAGS}\"/"
> ${WORKDIR}/init
> -	sed -i -e
> "s/__SWITCH_FOREGROUND_VT__/${SWITCH_FOREGROUND_VT}/"
> ${WORKDIR}/init
> 
>  	# Install the init script
>  	# TODO: replace init script with systemd files
> --
> 1.7.9.5
> 
> _______________________________________________
> meta-arago mailing list
> meta-arago@arago-project.org
> http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago


      reply	other threads:[~2015-03-17 15:43 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-17 14:39 [PATCH] matrix-gui: Clear background when starting and stopping matrix Jacob Stiffler
2015-03-17 15:43 ` Cooper Jr., Franklin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8F29D6B095ED194EA1980491A5E029710C848EA5@DFLE08.ent.ti.com \
    --to=fcooper@ti.com \
    --cc=j-stiffler@ti.com \
    --cc=meta-arago@arago-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.