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
Fix: #375 Pressing Enter during title editing saves the title #376
Conversation
|
Thanks. Reviewed. Changes requested;
Yes, you will find your Ubuntu 16.04 packaged environment hard to work in, because it uses Sugar 0.106 and we are now on Sugar 0.112. It causes your line 89 observation. You may either;
How to install the sugar-toolkit-gtk3 repository over your Ubuntu 16.04 Sugar Toolkit files This is a hack. It takes the Python source files of the toolkit and installs them over the top of whatever toolkit you have on your system from the From a clone of the sugar-toolkit-gtk3 repository, type this; It can be undone by reinstalling the package; Sugar 0.106 shell probably works fine with Sugar 0.112 toolkit, but if it doesn't ... How to install the sugar repository over your Ubuntu 16.04 Sugar files there's an equivalent overwrite for the shell repository http://github.com/sugarlabs/sugar ... I don't have time to simplify it, and I'll be absent for the weekend, so here's my upload to lab hardware script; #!/bin/bash -e
HOST=
PACK=dist-packages
NM=guest
DM=lightdm
RESTART=0
FULL=0
while [[ $# -gt 0 ]]; do
case $1 in
--restart)
RESTART=1
;;
--full)
FULL=1
;;
*)
HOST=$1
;;
*)
echo huh
exit 1
;;
esac
shift
done
rsync -r --checksum src/jarabe $HOST:/usr/lib/python2.7/$PACK/
rsync -r --checksum extensions $HOST:/usr/share/sugar/
if [ $FULL -eq 1 ]; then
rsync --checksum data/org.sugarlabs.gschema.xml \
$HOST:/usr/share/glib-2.0/schemas/
ssh $HOST glib-compile-schemas /usr/share/glib-2.0/schemas/
if [ -e data/activities.hidden ]; then
rsync data/activities.hidden $HOST:/usr/share/sugar/data/
fi
ssh $HOST rm -f usr/share/sugar/data/activities.defaults
sed 's%@prefix@%/usr%g' < bin/sugar.in | ssh $HOST "cat > /usr/bin/sugar"
fi
VERSION=$(grep AC_INIT configure.ac |cut -f3 -d'['|cut -f1 -d']')
sed "s%@SUCROSE_VERSION@%${VERSION}.git.$(date +%s)%g" < src/jarabe/config.py.in | \
sed 's%@prefix@%/usr%g' | \
ssh $HOST "cat > /usr/lib/python2.7/$PACK/jarabe/config.py"
if [ $RESTART -eq 1 ]; then
ssh $HOST "service $DM restart && sleep 3 && tail -f /home/$NM/.sugar/default/logs/shell.log"
fiHow to upgrade Sugar packages only to Ubuntu 18.04 beta versions
|
Problem Solved: Enter Key was ignored while editing TitleEntry Effect of this commit: Enter Key is now detected and the title is saved Fixes: #375 Explanation: 'activate' signal is binded to a function, which saves the title It calls self.entry.hide() and self.entry.show() to remove the cursor and focus from the titleEntry. Otherwise, the title gets saved but the cursor still remains in TitleEntry for further editing Approaches Used: Used key-press event for checking Enter key press - Works fine Used has_focus method to remove cursor - Didn't work Set Entry.editable to false - Didn't work modified: src/sugar3/activity/widgets.py
|
@quozl Thank you for the detailed review and installation guidance.
Changes done and tested |
|
@quozl |
|
Sorry for the silence. I've been testing and reviewing for some hours now, and was interrupted to fix some problems thrown up by my test cases. |
|
Thank you. Please let me know if there are any issues. |
|
Thanks. I've cherry-picked and merged your change and added some of my own. This isn't a complete fix for #375, but it is a start. If you have any further changes, please rebase your branch and push new commits. |
|
Unrelated to the pull request ... @Pro-Panda, a couple of HFOSS volunteers asked how to update Ubuntu 16.04, and I've pointed them to my comment above and to our discussion on IRC. Do you plan to update the Wiki? |
|
I created an account for you.
…On Wed, Jan 17, 2018 at 10:36 PM, Rahul Bothra ***@***.***> wrote:
@quozl <https://github.com/quozl>, I don't have a wiki login access,
needed to create a page
<https://wiki.sugarlabs.org/go/Wiki_Team/Guide/Page_Creation>. Should I
apply for one ?
Thanks
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#376 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ADz74WJZMutdSoEyS0EsabXVbRBkQvwbks5tLrw-gaJpZM4Rcorg>
.
--
Walter Bender
Sugar Labs
http://www.sugarlabs.org
<http://www.sugarlabs.org>
|
|
@walterbender Thank you |
|
Looks like nothing else is forthcoming, so I'll close this pull request for the moment. |
|
Apologies. |
Fixed in this PR: #375 sugar3.activity.widgets.TitleEntry ignores enter key
Fix: Connected Key-Press event to a function which saves the title on detecting
enterTested on: Packaged environment (using rdesktop) on Ubuntu 16.04
Activities on which tested:
@quozl kindly review.
Also, please point my mistakes in commit/PR style, if any.
Note: I don't have line:89 in my version of sucrose.
Activities fail to load on adding it, Err: No
add_stop_buttonfunction in activity.Works fine without that line