|
Last change
on this file was
18125,
checked in by westram, 6 years ago
|
- full update from 'trunk' into 'nameserver'
- adds:
|
|
File size:
1.4 KB
|
| Line | |
|---|
| 1 | // ============================================================== // |
|---|
| 2 | // // |
|---|
| 3 | // File : AliAdmin.cxx // |
|---|
| 4 | // Purpose : Provide alignment admin functionality // |
|---|
| 5 | // to NTREE and MERGE // |
|---|
| 6 | // // |
|---|
| 7 | // Coded by Ralf Westram (coder@reallysoft.de) in August 2014 // |
|---|
| 8 | // http://www.arb-home.de/ // |
|---|
| 9 | // // |
|---|
| 10 | // ============================================================== // |
|---|
| 11 | |
|---|
| 12 | #include "AliAdmin.h" |
|---|
| 13 | #include <cctype> |
|---|
| 14 | #include <aw_window.hxx> |
|---|
| 15 | |
|---|
| 16 | static struct { |
|---|
| 17 | const char *id, *title; |
|---|
| 18 | } ALIGNMENT[ALI_ADMIN_TYPES] = { |
|---|
| 19 | { "ALIGNMENT", "alignment" }, |
|---|
| 20 | { "SOURCE_ALIGNMENT", "source alignment" }, |
|---|
| 21 | { "TARGET_ALIGNMENT", "target alignment" }, |
|---|
| 22 | }; |
|---|
| 23 | |
|---|
| 24 | void AliAdmin::window_init(AW_window_simple *aw, const char *id_templ, const char *title_templ) const { |
|---|
| 25 | char *id = GBS_global_string_copy(id_templ, ALIGNMENT[type].id); |
|---|
| 26 | char *title = GBS_global_string_copy(title_templ, ALIGNMENT[type].title); |
|---|
| 27 | |
|---|
| 28 | title[0] = toupper(title[0]); |
|---|
| 29 | |
|---|
| 30 | aw->init(AW_root::SINGLETON, id, title); |
|---|
| 31 | |
|---|
| 32 | free(title); |
|---|
| 33 | free(id); |
|---|
| 34 | } |
|---|
| 35 | |
|---|
| 36 | // -------------------------------------------------------------------------------- |
|---|
| 37 | |
|---|
Note: See
TracBrowser
for help on using the repository browser.