| 1 | // ==================================================================== // |
|---|
| 2 | // // |
|---|
| 3 | // File : aw_advice.hxx // |
|---|
| 4 | // Purpose : general user advices // |
|---|
| 5 | // // |
|---|
| 6 | // // |
|---|
| 7 | // Coded by Ralf Westram (coder@reallysoft.de) in May 2002 // |
|---|
| 8 | // Copyright Department of Microbiology (Technical University Munich) // |
|---|
| 9 | // // |
|---|
| 10 | // Visit our web site at: http://www.arb-home.de/ // |
|---|
| 11 | // // |
|---|
| 12 | // // |
|---|
| 13 | // ==================================================================== // |
|---|
| 14 | |
|---|
| 15 | #ifndef AW_ADVICE_HXX |
|---|
| 16 | #define AW_ADVICE_HXX |
|---|
| 17 | |
|---|
| 18 | #ifndef AW_BASE_HXX |
|---|
| 19 | #include "aw_base.hxx" |
|---|
| 20 | #endif |
|---|
| 21 | |
|---|
| 22 | |
|---|
| 23 | //! define type of @ref AW_advice by or-ing values |
|---|
| 24 | enum AW_Advice_Type { |
|---|
| 25 | AW_ADVICE_SIMPLE = 0, // nothing of the following |
|---|
| 26 | AW_ADVICE_TOGGLE = 1, // visible toggle to switch off advice (otherwise advice appears only once) |
|---|
| 27 | AW_ADVICE_HELP = 2, // advice has corresponding help file |
|---|
| 28 | AW_ADVICE_HELP_POPUP = 4, // this helpfile should popup immediately |
|---|
| 29 | |
|---|
| 30 | // convenience defs: |
|---|
| 31 | AW_ADVICE_TOGGLE_AND_HELP = AW_ADVICE_TOGGLE|AW_ADVICE_HELP, |
|---|
| 32 | }; |
|---|
| 33 | |
|---|
| 34 | //! has to be called one time (before calling AW_advice) |
|---|
| 35 | void init_Advisor(AW_root *awr); |
|---|
| 36 | |
|---|
| 37 | /*! @brief Show a message box with an advice for the user |
|---|
| 38 | @param message the text shown to the user |
|---|
| 39 | @param title window title |
|---|
| 40 | @param type type of advice |
|---|
| 41 | @param corresponding_help name of corresponding ARB-helpfile |
|---|
| 42 | @see init_Advisor |
|---|
| 43 | */ |
|---|
| 44 | void AW_advice(const char *message, |
|---|
| 45 | AW_Advice_Type type = AW_ADVICE_SIMPLE, |
|---|
| 46 | const char *title = NULp, |
|---|
| 47 | const char *corresponding_help = NULp); |
|---|
| 48 | |
|---|
| 49 | //! reactivates all advices which were disabled by the user |
|---|
| 50 | void AW_reactivate_all_advices(AW_window*); |
|---|
| 51 | |
|---|
| 52 | |
|---|
| 53 | #else |
|---|
| 54 | #error aw_advice.hxx included twice |
|---|
| 55 | #endif // AW_ADVICE_HXX |
|---|
| 56 | |
|---|