File: | select/properties/pitch.c |
Warning: | line 26, column 4 Value stored to 'freq' is never read |
Press '?' to see keyboard shortcuts
Keyboard shortcuts:
1 | /* |
2 | * This file is part of LibCSS |
3 | * Licensed under the MIT License, |
4 | * http://www.opensource.org/licenses/mit-license.php |
5 | * Copyright 2009 John-Mark Bell <jmb@netsurf-browser.org> |
6 | */ |
7 | |
8 | #include "bytecode/bytecode.h" |
9 | #include "bytecode/opcodes.h" |
10 | #include "select/propset.h" |
11 | #include "select/propget.h" |
12 | #include "utils/utils.h" |
13 | |
14 | #include "select/properties/properties.h" |
15 | #include "select/properties/helpers.h" |
16 | |
17 | css_error css__cascade_pitch(uint32_t opv, css_style *style, |
18 | css_select_state *state) |
19 | { |
20 | css_fixed freq = 0; |
21 | uint32_t unit = UNIT_HZ; |
22 | |
23 | if (hasFlagValue(opv) == false0) { |
24 | switch (getValue(opv)) { |
25 | case PITCH_FREQUENCY: |
26 | freq = *((css_fixed *) style->bytecode); |
Value stored to 'freq' is never read | |
27 | advance_bytecode(style, sizeof(freq)); |
28 | unit = *((uint32_t *) style->bytecode); |
29 | advance_bytecode(style, sizeof(unit)); |
30 | break; |
31 | case PITCH_X_LOW: |
32 | case PITCH_LOW: |
33 | case PITCH_MEDIUM: |
34 | case PITCH_HIGH: |
35 | case PITCH_X_HIGH: |
36 | /** \todo convert to public values */ |
37 | break; |
38 | case PITCH_CALC: |
39 | advance_bytecode(style, sizeof(unit)); |
40 | advance_bytecode(style, sizeof(unit)); // TODO |
41 | return CSS_OK; |
42 | default: |
43 | assert(0 && "Invalid value")((0 && "Invalid value") ? (void) (0) : __assert_fail ( "0 && \"Invalid value\"", "src/select/properties/pitch.c" , 43, __extension__ __PRETTY_FUNCTION__)); |
44 | break; |
45 | } |
46 | } |
47 | |
48 | unit = css__to_css_unit(unit); |
49 | |
50 | if (css__outranks_existing(getOpcode(opv), isImportant(opv), state, |
51 | getFlagValue(opv))) { |
52 | /** \todo pitch */ |
53 | } |
54 | |
55 | return CSS_OK; |
56 | } |
57 | |
58 | css_error css__set_pitch_from_hint(const css_hint *hint, |
59 | css_computed_style *style) |
60 | { |
61 | UNUSED(hint)((void)(hint)); |
62 | UNUSED(style)((void)(style)); |
63 | |
64 | return CSS_OK; |
65 | } |
66 | |
67 | css_error css__initial_pitch(css_select_state *state) |
68 | { |
69 | UNUSED(state)((void)(state)); |
70 | |
71 | return CSS_OK; |
72 | } |
73 | |
74 | css_error css__copy_pitch( |
75 | const css_computed_style *from, |
76 | css_computed_style *to) |
77 | { |
78 | UNUSED(from)((void)(from)); |
79 | UNUSED(to)((void)(to)); |
80 | |
81 | return CSS_OK; |
82 | } |
83 | |
84 | css_error css__compose_pitch(const css_computed_style *parent, |
85 | const css_computed_style *child, |
86 | css_computed_style *result) |
87 | { |
88 | UNUSED(parent)((void)(parent)); |
89 | UNUSED(child)((void)(child)); |
90 | UNUSED(result)((void)(result)); |
91 | |
92 | return CSS_OK; |
93 | } |
94 |