Opened 16 years ago
Closed 15 years ago
#3044 closed bug (fixed)
[JPEG2000] shows an alert if it can't find his settings (easy)
Reported by: | diver | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | Add-Ons/Translators | Version: | R1/pre-alpha1 |
Keywords: | Cc: | fredrik@… | |
Blocked By: | Blocking: | ||
Platform: | All |
Description
Attachments (2)
Change History (12)
by , 16 years ago
Attachment: | jpeg2000.png added |
---|
comment:1 by , 16 years ago
Summary: | [JPEG2000] shows an alert if it can't find his settings → [JPEG2000] shows an alert if it can't find his settings (easy) |
---|
comment:2 by , 16 years ago
Cc: | added |
---|
comment:3 by , 16 years ago
I mean that no other translator show such alert and silently creates one if needed. Also note that alert message is about incompatible settings file, but there were no settings file before, as this is the first time I opened JPEG2000 image.
comment:4 by , 16 years ago
Hi, I've attached a path for this.
With this patch the alert is now only shown if the translator attempts to read a settings file and fails (i.e. it's corrupt or otherwise incompatible - as suggested in the message).
In the case of there not being a settings file the translator will silently create the default (this is also the behaviour of the other translators as far as I can see).
Cheers,
Richy
comment:5 by , 16 years ago
A translator should never show an alert, since it could be used from a command line application. The JPEG translator had also this issue, and was fixed by removing the code which showed the alert. If anything, you could dump a message to the syslog.
comment:6 by , 16 years ago
Ok, I'll ammend the patch to remove all the alerts and check the other translators.
comment:7 by , 16 years ago
Actually, the jpeg translator can still show an alert in the same circumstances (corrupt or unreadable settings file) just not when it's silently creating one. The attached patch brings the j2k translator into line with this.
Should I remove the other alert from both?
follow-up: 10 comment:9 by , 16 years ago
No worries, I'm happy to help and starting with some of these tickets seems a good way to get familiar with the code/build/etc.
I've attached a new patch which removes the alert from both jpeg and jpeg2k translators and also cleans up other BAlert statements that the j2k translator could have popped up (replaced with logging to stderr, which is what the other translators seem to do).
comment:10 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Replying to richy_rich:
Applied in hrev31873. Thanks!
And the solution are to remove that alert? or are the image a propose how it can look and the hedline shoul be "show an alert if it can't find his settings"?