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

Editing the Code Objects list: rename, reorder #43

Open
SarahBu07 opened this issue Jun 14, 2017 · 6 comments
Open

Editing the Code Objects list: rename, reorder #43

SarahBu07 opened this issue Jun 14, 2017 · 6 comments

Comments

@SarahBu07
Copy link

SarahBu07 commented Jun 14, 2017

When we choose and select several playground samples, we got a list, and it's not possible to delete one or several items in the list, or even the entire list. So we could add a delete button for each item and even add a reset button to start again from scratch.
@Korayaz

@juliendorra
Copy link
Collaborator

juliendorra commented Jun 14, 2017

Are you talking about the playground list here : www.paysage.xyz/list ?
If so: As we can create new, blank playground without limits, what would be the use case of deleting existing Playgrounds? It could be very destructive without real benefits that I can see.

But maybe you are talking about the code object list on the Programmer page (ex of programmer page: www.paysage.xyz/playground/monterraindejeu/programmer )
In this second case, there might be a use case for deleting, renaming the code objects…So we could work on defining a better edit interface on the programmer.

@jonathanperret
Copy link
Owner

As I understand it, @SarahBu07 is talking about the "creature list" in the programmer. Agreed that there wouldn't be much point in deleting a playground.

Buttons to delete objects would definitely be a useful addition. Reordering would be nice too…

@juliendorra
Copy link
Collaborator

Ok, so with reordering, deleting and renaming: renaming the issue to reflect the need for better edit UI/flow of the code object list

@juliendorra juliendorra changed the title Add delete button for each playground in the list Editing the Code Objects list: delete, rename, reorder Jun 14, 2017
@SarahBu07
Copy link
Author

Totally agree for the reordering, so we could choose which creature we want to have above or under each other...

@juliendorra
Copy link
Collaborator

Re-ordering would be very useful.
It touch the programmer page and the server. The renderer doesn't need to know anything about it, as it will just update and re-render in the order the objects are send.
It could be done that way:

  • programmer send a re-order message, with the complete list => new UI and new json/socket io message to server
  • server parse the array containing the code objects and re-order them => new route to listen to, new function to re-order the playground list/array of code objects
  • server send a full update (using the existing full update function)

jonathanperret added a commit that referenced this issue Aug 8, 2017
@jonathanperret jonathanperret changed the title Editing the Code Objects list: delete, rename, reorder Editing the Code Objects list: rename, reorder Sep 20, 2017
@juliendorra
Copy link
Collaborator

juliendorra commented Oct 10, 2017

Now that we have a delete function (thanks @etienneCharignon!), a "send to foreground" action is easy to implement locally in the programmer, without any new code server-side or render-side:
we can combine a delete and a re-send of the code with the same code object ID.

The new canvas for rendering the newer code object is added on the top of previous canvas, so delete+re-send will actually place a code object in front of all the others.

That would work that way:

  • user click the [top/foreground] button next to a code object name in the list (placed far enough from the delete button to avoid mis-clicking!)
  • code and ID are prepared as for a code update, but not sent
  • delete code object is sent
  • code update is now sent
  • same code and ID appears on top of others (but at the bottom the list! should we inverse that as photoshop layers? see Code objects list in programmer reversed compared to canvases #79)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants