[rfc][icedtea-web][policyeditor] Disable "paste" until "copy" is performed

Jiri Vanek jvanek at redhat.com
Mon Jun 30 14:53:19 UTC 2014


On 06/30/2014 04:33 PM, Andrew Azores wrote:
> Yes, that would be very nice if that work flow could be supported. I'll have Lukasz and/or Jie work with me on this so there's an excuse to make them learn this part of the ITW/PE codebase too ;)
>

If copypaste is in 1.5, then I'm ok with this to 1.5 But for Head I'm strongly for rework the clipboard handling in PE. And so it means that this patch is not necessary.

J.

>
> Andrew A
>
> ----- Original Message -----
>> On 06/30/2014 04:19 PM, Andrew Azores wrote:
>>> I didn't think it really made sense to be able to copy/paste actual policy
>>> file codebase entry contents, particularly since PolicyEditor doesn't
>>> actually have full support right now for everything that can go into a
>>> policy file eg certain structures of comments or the "principal" attribute
>>> or however you call it. You can copy the selected codebase URL to the
>>> system clipboard though, and you can paste your system clipboard contents
>>> into the "New Codebase" dialog which prompts for a codebase URL.
>>>
>>
>> Yes. I'm (now a bit more:) aware of this.
>>
>> What about the case when one have more  PoliciEditors running? He would be
>> expecting th transfer things via copy/paste actions. And the buttons are
>> suggesting, he can.
>>
>> The patch itself is good for simple case how it is done now. But it does not
>> mean it is the best way how it is handled.
>>>
>>> Andrew A
>>>
>>> ----- Original Message -----
>>>> On 06/30/2014 04:07 PM, Andrew Azores wrote:
>>>>> Hi,
>>>>>
>>>>> The "Copy" in question copies the permissions for a codebase in the
>>>>> PolicyEditor. Then when you go to "Paste", it asks you for a new codebase
>>>>> URL, and creates a new entry in the editor with that URL but all of the
>>>>> permissions duplicated from the codebase that you copied. So there isn't
>>>>> really any way to "copy it from somewhere else" as it doesn't actually
>>>>> use
>>>>> the system clipboard, just a "clipboard" within PolicyEditor.
>>>>>
>>>> Oh thats misleading.
>>>>
>>>> Wouldn't be better to have proper clipboard function?
>>>>
>>>>
>>>>>
>>>>> Andrew A
>>>>>
>>>>> ----- Original Message -----
>>>>>> On 06/27/2014 05:27 PM, Andrew Azores wrote:
>>>>>>> Hi,
>>>>>>>
>>>>>>> This patch adds a check in the "paste" button action so that the dialog
>>>>>>> prompting the user for the new URL to paste with does not appear if a
>>>>>>> codebase has not been previously copied. This would also guard against
>>>>>>> the
>>>>>>> dialog appearing when a keyboard shortcut is used to paste.
>>>>>>> Additionally,
>>>>>>> the "paste" button in the Edit menu is now disabled until "copy" has
>>>>>>> been
>>>>>>> pressed for the first time.
>>>>>>>
>>>>>>> Thanks,
>>>>>>>
>>>>>> This seems a bit wrong to me.
>>>>>>
>>>>>> What if user copied it from somewhere else?
>>>>>>
>>>>>> I was not checking the original "add copy and paste" functinality but.
>>>>>>
>>>>>> What is codebase?
>>>>>>
>>>>>> If it is plain string, then you definitely should not do this.
>>>>>>      - Just check if something is in clipboard, and if it is string,
>>>>>>      enable
>>>>>>      paste.
>>>>>>
>>>>>> If it si not string, have it its own flavour, or syntax which cna be
>>>>>> recognized?
>>>>>>      - If so, and it was recognized as codebase, please, enable paste it.
>>>>>>
>>>>>> Otherwise disable paste, and if ctrl+v is forced,, then show error.
>>>>>>
>>>>>>
>>>>>> What do you think?
>>>>>>
>>>>>>       J.
>>>>>>
>>>>
>>>>
>>
>>



More information about the distro-pkg-dev mailing list