Guy Harris wrote:
>On Sat, Mar 08, 2003 at 02:16:40PM +0000, Richard Urwin wrote:
>> I have the first part of this as a first cut, and I would like any comments
>> that people have.
>
>"get_datafile_path()" doesn't need a "for_writing" argument; the only
>reason "get_persconffile_path()" has one is to allow a
>backwards-compatibility hack to read configuration files from the days
>when, on Windows, configuration files were stored in a ".ethereal"
>subdirectory of the user's "home directory" (which isn't really the same
>thing on Windows as on UNIX).
>
>> The global colorfilters file resides in the "data directory"; /usr/local/etc
>> on my machine. This needs superuser permission to create, but that is
>> probably as required. Is this the correct place? Maybe we need to create an
>> Ethereal subdirectory?
>
>A subdirectory of the data directory might be a good idea, just to keep
>Ethereal's files separate from other files. (Actually, that
>subdirectory would *become* the data directory.)
>
>> When the color filters dialog is invoked, all of the filters, global and local
>> are displayed. When these filters are saved they are all saved to the local
>> file, and the global file is not reread. So, on the current session, the user
>> can remove the global filters if they wish. This (emergent) behavior seems to
>> work well. What do you think? The next time Ethereal is started the global
>> filters will again operate, giving the possibility of a difference in
>> behavior that the user is not expecting. Is this a problem?
>
>I think it'd be a bit surprising if the user were to change filters,
>save them, and have a new session behave differently from the session in
>which they changed and saved the filters.
>
>It *would* be useful to let users remove the global filters permanently,
>if they didn't want them. If you save all filters to the local file,
>it'd probably be sufficient to read the local filter file if there is
>one and the global filter file if there isn't one, and perhaps have a
>"revert to factory settings" option to discard the local filter file.
>
I haven't thought so much about it yet and haven't read so much about the previous discussions.
But maybe it would be good to have a checkbox (or similar) telling if a specific filter is active or not instead of having to remove the entries you don't want to have active. The indication whether the filter is active or not should be stored in the file so that the status doesn't changed next time Ethereal is used.
Maybe you want to have some filters specified that you don't want to have active all the time.
When you start Ethereal it should read the local filter file if there is one and use the active ones in that
file. If there is no local file it should read the global filter file and use the filters in that one.
If you enter the color filter dialog you should maybe see both the entries from the global file and the local file
(both active and not active - together with an indication whether they are active/not active and maybe also
whether the filter is global/local).
If you activate one of the global filters it should be stored in the local filter file as active.
This is not my final suggestion since I haven't thought so much about it yet, but just some preliminar ideas.