/*------------------------------------------------------------------------------
 src/plugin/djImageIoJpeg/widget.h
 
 Copyright (c) 2004-2006 Darby Johnston.
 All rights reserved.
 Use is subject to license terms.
------------------------------------------------------------------------------*/

#ifndef DJ_IMAGE_IO_JPEG_WIDGET_H
#define DJ_IMAGE_IO_JPEG_WIDGET_H
#include "io.h"
#include <djImageIoWidget.h>

namespace dj {
class IntWidget;
class IntSliderWidget;
}

namespace djImageIoJpeg {

// Image save widget.
//
class SaveWidget : public ImageSaveWidget {
public:

  SaveWidget();

  const Str name() const { return djImageIoJpeg::name(); }
  Plugin * copy() const { return new SaveWidget; }

  void set(ImageSave *);
  void widgetUpdate();

private:

  DJ_CALLBACK(SaveWidget, qualityCallback, int)

  IntWidget * _qualityWidget;
  IntSliderWidget * _qualitySlider;
  bool _callbacks;
};

}

#endif
