map keys and handle key events on Android and OS X

This commit is contained in:
2017-04-17 19:35:48 +02:00
parent 54082591f1
commit 45cf8c9168
11 changed files with 595 additions and 68 deletions

View File

@@ -58,12 +58,12 @@ public:
}
virtual void undo() override
{
m_canvas->m_layers[m_stroke->m_layer].m_rtt.bindTexture();
m_canvas->m_layers[m_layer_idx].m_rtt.bindTexture();
glm::vec2 box_sz = m_box.zw() - m_box.xy();
glTexSubImage2D(GL_TEXTURE_2D, 0, m_box.x, m_box.y, box_sz.x, box_sz.y, GL_RGBA, GL_UNSIGNED_BYTE, m_image.get());
m_canvas->m_layers[m_stroke->m_layer].m_rtt.unbindTexture();
m_canvas->m_layers[m_layer_idx].m_rtt.unbindTexture();
}
};