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

[0.3.1] Copy-Paste Node does not modify Namespace id of browename and nodeid #31

Open
Stasik0 opened this issue Nov 17, 2016 · 4 comments

Comments

@Stasik0
Copy link

Stasik0 commented Nov 17, 2016

Copy-paste should be of paste-environment and adjust Browsename accoringly
Also id generation should be consideren

@oroulet
Copy link
Member

oroulet commented Nov 17, 2016

Can you explain further you explanantion? when copying a new nodeid is
created and the original browse name is kept. how do you think it should
behave?

On Thu, 17 Nov 2016 at 12:37 Sten Grüner notifications@github.com wrote:

Copy-paste should be of paste-environment and adjust Browsename acoringly


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#31, or mute the thread
https://github.com/notifications/unsubscribe-auth/ACcfztksvHfY1VUzy68BhrOx9dDg9Hhkks5q_Dx2gaJpZM4K1Mt0
.

@Stasik0
Copy link
Author

Stasik0 commented Nov 17, 2016

There is a Browsename in format "nsid:String" and there is a nodeid as a struct with nsid and so on.

If I paste a node where a context is clear e.g. an attribute form node in NS0 and paste it as a child of type in NSX, I'd like that browsename is changed from "0:bla" to "X:bla" and the NS id in the new nodeid is change accordingly. Furthermore, a popup would be good to ask me to enter or generate a unique nodid in new namespace.

What do you think?

@oroulet
Copy link
Member

oroulet commented Nov 17, 2016

Showing a dialog is a good idea. We can ask for namespace. But asking for
node IDs seems difficult, there may be many nodes created...

On Thu, Nov 17, 2016, 14:14 Sten Grüner notifications@github.com wrote:

There is a Browsename in format "nsid:String" and there is a nodeid as a
struct with nsid and so on.

If I paste a node where a context is clear e.g. an attribute form node in
NS0 and paste it as a child of type in NSX, I'd like that browsename is
changed from "0:bla" to "X:bla" and the NS id in the new nodeid is change
accordingly. Furthermore, a popup would be good to ask me to enter or
generate a unique nodid in new namespace.

What do you think?


You are receiving this because you commented.

Reply to this email directly, view it on GitHub
#31 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACcfztqLPQbq7MPEfLPJL-b2NqdaFK-Gks5q_FNIgaJpZM4K1Mt0
.

@zerox1212
Copy link
Collaborator

zerox1212 commented Nov 17, 2016

To be honest I never use copy paste when I'm using modeler, but it seems like we would only need to choose a namespace for pasting. Then we can use the existing "new node" convention, which is like this:

  1. Auto node id uses counter specific for each address space; this counter auto increments
  2. Create own node id by typeing, and you need to type the "ns=x" yourself; if you make an int or string node id all child node ids will follow the same convention

In a previous PR I tired to make ns=x automatically match the selected namespace, but @oroulet said that user should type it. I don't really understand why, but that's how it is for now.

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

No branches or pull requests

3 participants