all repos — fluxbox @ d2e0aea0ae29289b44a82e66c44a9545a71b0d67

custom fork of the fluxbox windowmanager

added menu icon
fluxgen fluxgen
commit

d2e0aea0ae29289b44a82e66c44a9545a71b0d67

parent

80ba32fb2dac1240a0fbcc9895e9ea75e8ccc485

2 files changed, 13 insertions(+), 3 deletions(-)

jump to
M src/FbMenuParser.ccsrc/FbMenuParser.cc

@@ -20,7 +20,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbMenuParser.cc,v 1.1 2004/05/02 21:02:26 fluxgen Exp $ +// $Id: FbMenuParser.cc,v 1.2 2004/06/10 11:42:35 fluxgen Exp $ #include "FbMenuParser.hh"

@@ -58,6 +58,10 @@ break;

case ARGUMENT: first = '{'; second = '}'; + break; + case ICON: + first = '<'; + second = '>'; break; case DONE: // get new line and call this again if (!nextLine()) {

@@ -78,6 +82,8 @@ m_curr_token = NAME;

else if (m_curr_token == NAME) m_curr_token = ARGUMENT; else if (m_curr_token == ARGUMENT) + m_curr_token = ICON; + else if (m_curr_token == ICON) m_curr_token = DONE; out = Parser::s_empty_item;

@@ -101,6 +107,10 @@ m_curr_token = ARGUMENT;

break; case ARGUMENT: out.first = "ARGUMENT"; + m_curr_token = ICON; + break; + case ICON: + out.first = "ICON"; m_curr_token = DONE; break; case DONE:
M src/FbMenuParser.hhsrc/FbMenuParser.hh

@@ -20,7 +20,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbMenuParser.hh,v 1.1 2004/05/02 21:02:26 fluxgen Exp $ +// $Id: FbMenuParser.hh,v 1.2 2004/06/10 11:42:35 fluxgen Exp $ #ifndef FBMENUPARSER_HH #define FBMENUPARSER_HH

@@ -52,7 +52,7 @@ mutable std::ifstream m_file;

int m_row; int m_curr_pos; std::string m_curr_line; - enum Object {TYPE, NAME, ARGUMENT, DONE} m_curr_token; + enum Object {TYPE, NAME, ARGUMENT, ICON, DONE} m_curr_token; }; #endif // FBMENUPARSER_HH