mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-12-29 12:26:01 +01:00
Enable t in sc_rotate
This commit is contained in:
parent
036dc0cd57
commit
d882bf9cd8
1 changed files with 3 additions and 2 deletions
|
@ -444,7 +444,7 @@ sc_reload(girara_session_t* session, girara_argument_t* UNUSED(argument),
|
|||
|
||||
bool
|
||||
sc_rotate(girara_session_t* session, girara_argument_t* argument,
|
||||
girara_event_t* UNUSED(event), unsigned int UNUSED(t))
|
||||
girara_event_t* UNUSED(event), unsigned int t)
|
||||
{
|
||||
g_return_val_if_fail(session != NULL, false);
|
||||
g_return_val_if_fail(session->global.data != NULL, false);
|
||||
|
@ -459,8 +459,9 @@ sc_rotate(girara_session_t* session, girara_argument_t* argument,
|
|||
}
|
||||
|
||||
/* update rotate value */
|
||||
t = (t == 0) ? 1 : t;
|
||||
unsigned int rotation = zathura_document_get_rotation(zathura->document);
|
||||
zathura_document_set_rotation(zathura->document, (rotation + angle) % 360);
|
||||
zathura_document_set_rotation(zathura->document, (rotation + angle * t) % 360);
|
||||
|
||||
/* update scale */
|
||||
girara_argument_t new_argument = { zathura_document_get_adjust_mode(zathura->document), NULL };
|
||||
|
|
Loading…
Reference in a new issue