| 6018 | } |
| 6019 | |
| 6020 | static bool |
| 6021 | edit_mode_from_title (const std::string &title) |
| 6022 | { |
| 6023 | std::string s = title; |
| 6024 | std::string::size_type tab = s.find ('\t'); |
| 6025 | if (tab != std::string::npos) { |
| 6026 | s = std::string (s, 0, tab); |
| 6027 | } |
| 6028 | std::vector<std::string> parts = tl::split (s, ":"); |
| 6029 | for (auto i = parts.begin (); i != parts.end (); ++i) { |
| 6030 | if (*i == "edit_mode") { |
| 6031 | return true; |
| 6032 | } |
| 6033 | } |
| 6034 | return false; |
| 6035 | } |
| 6036 | |
| 6037 | std::vector<std::string> |
| 6038 | LayoutViewBase::mode_names () const |