stlab.adobe.com Adobe Systems Incorporated

platform_progress_bar.hpp

Go to the documentation of this file.
00001 /*
00002     Copyright 2005-2007 Adobe Systems Incorporated
00003     Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt
00004     or a copy at http://stlab.adobe.com/licenses.html)
00005 */
00006 
00007 /****************************************************************************************************/
00008 
00009 #ifndef ADOBE_PROGRESS_BAR_HPP
00010 #define ADOBE_PROGRESS_BAR_HPP
00011 
00012 #include <adobe/config.hpp>
00013 
00014 #include <boost/utility.hpp>
00015 
00016 #include <adobe/any_regular.hpp>
00017 #include <adobe/extents.hpp>
00018 #include <adobe/layout_attributes.hpp>
00019 #include <adobe/widget_attributes.hpp>
00020 #include <adobe/future/widgets/headers/widget_utils.hpp>
00021 #include <adobe/future/widgets/headers/value_range_format.hpp>
00022 
00023 /****************************************************************************************************/
00024 
00025 namespace adobe {
00026 
00027 /****************************************************************************************************/
00028 
00039 enum pb_style_t
00040 {
00043     pb_style_progress_bar_s,
00044 
00048     pb_style_relevance_bar_s,
00049 
00054     pb_style_indeterminate_bar_s
00055 };
00056 
00057 /****************************************************************************************************/
00058 
00059 struct progress_bar_t : boost::noncopyable
00060 {
00061     typedef     progress_bar_t   widget_type_t;
00062     typedef     any_regular_t    model_type;
00063     
00064                 progress_bar_t(pb_style_t bar_style, 
00065                                bool is_vertical,
00066                                const value_range_format_t& format,
00067                                unsigned long min,
00068                                unsigned long max,
00069                                theme_t theme);
00070    
00071     void        measure(extents_t& result);
00072     void        place(const place_data_t& place_data);
00073 
00074     void        display(const any_regular_t& value);
00075 
00076     void        initialize(HWND parent);                         
00077 
00078     void        set_min_value(long min_value);
00079     void        set_max_value(long max_value);
00080 
00081     HWND                        control_m;
00082 
00083 private:
00084     pb_style_t                  bar_style_m;
00085     bool                        is_vertical_m;
00086 
00087     double                      last_m;
00088     double                      value_m;
00089     value_range_format_t format_m;
00090     theme_t              theme_m;
00091 };
00092 
00093 /****************************************************************************************************/
00094 
00095 }
00096 
00097 /****************************************************************************************************/
00098 
00099 #endif

Copyright © 2006-2007 Adobe Systems Incorporated.

Use of this website signifies your agreement to the Terms of Use and Online Privacy Policy.

Search powered by Google