Skip to content
This repository was archived by the owner on Jan 30, 2025. It is now read-only.

Commit

Permalink
CPPLINT: disable whitespace/indent
Browse files Browse the repository at this point in the history
We rely on clang-format in platform2 to adjust whitespace for us,
so having the linter also enforce a set of rules isn't useful, and
it could even be conflicting.

BUG=b:296968204
TEST=`cros lint` is clean here

Change-Id: Ieb55d673df181bea574d2741dbd30c7b675206b0
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/4804940
Tested-by: Mike Frysinger <[email protected]>
Reviewed-by: Nic Hollingum <[email protected]>
Owners-Override: Mike Frysinger <[email protected]>
Reviewed-by: Hidehiko Abe <[email protected]>
Commit-Queue: Mike Frysinger <[email protected]>
  • Loading branch information
vapier authored and Chromeos LUCI committed Aug 24, 2023
1 parent 9652ab2 commit 1917175
Show file tree
Hide file tree
Showing 12 changed files with 23 additions and 23 deletions.
2 changes: 1 addition & 1 deletion compositor/sommelier-compositor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ static void sl_host_surface_attach(struct wl_client* client,
break;
}
}
} // NOLINT(whitespace/indent)
}

// Return the scale and offset from surface coordinates to buffer pixel
// coordinates, taking the viewport into account (if any).
Expand Down
8 changes: 4 additions & 4 deletions sommelier-data-device-manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -351,12 +351,12 @@ static void sl_data_device_start_drag(struct wl_client* client,
host_source ? host_source->proxy : nullptr,
host_origin ? host_origin->proxy : nullptr,
host_icon ? host_icon->proxy : nullptr, serial);
} // NOLINT(whitespace/indent)
}

static void sl_data_device_release(struct wl_client* client,
struct wl_resource* resource) {
wl_resource_destroy(resource);
} // NOLINT(whitespace/indent)
}

static const struct wl_data_device_interface sl_data_device_implementation = {
sl_data_device_start_drag,
Expand Down Expand Up @@ -405,7 +405,7 @@ static void sl_data_device_enter(void* data,

wl_data_device_send_enter(host->resource, serial, host_surface->resource, ix,
iy, host_data_offer->resource);
} // NOLINT(whitespace/indent)
}

static void sl_data_device_leave(void* data,
struct wl_data_device* data_device) {
Expand Down Expand Up @@ -512,7 +512,7 @@ static void sl_data_device_manager_get_data_device(
wl_data_device_manager_get_data_device(host->proxy, host_seat->proxy);
wl_data_device_add_listener(host_data_device->proxy, &sl_data_device_listener,
host_data_device);
} // NOLINT(whitespace/indent)
}

static const struct wl_data_device_manager_interface
sl_data_device_manager_implementation = {
Expand Down
2 changes: 1 addition & 1 deletion sommelier-gaming.cc
Original file line number Diff line number Diff line change
Expand Up @@ -676,7 +676,7 @@ static void sl_internal_gaming_seat_gamepad_added_with_device_info(
host_gamepad->name, host_gamepad->bus, host_gamepad->vendor_id,
host_gamepad->product_id, host_gamepad->version,
(host_gamepad->input_mapping) ? host_gamepad->input_mapping->id : "none");
} // NOLINT(whitespace/indent), lint bug b/173143790
}

// Note: not currently implemented by Exo.
static void sl_internal_gaming_seat_gamepad_added(
Expand Down
4 changes: 2 additions & 2 deletions sommelier-gtk-shell.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "sommelier.h" // NOLINT(build/include_directory)
#include "sommelier.h" // NOLINT(build/include_directory)
#include "sommelier-tracing.h" // NOLINT(build/include_directory)

#include <assert.h>
Expand Down Expand Up @@ -45,7 +45,7 @@ static void sl_gtk_surface_set_dbus_properties(
host->aura_shell->ctx->vm_id, application_id);

zaura_surface_set_application_id(host->proxy, application_id_str);
} // NOLINT(whitespace/indent)
}

static const struct gtk_surface1_interface sl_gtk_surface_implementation = {
sl_gtk_surface_set_dbus_properties, /*set_modal=*/DoNothing,
Expand Down
4 changes: 2 additions & 2 deletions sommelier-pointer-constraints.cc
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ static void sl_pointer_constraints_lock_pointer(struct wl_client* client,
zwp_locked_pointer_v1_add_listener(locked_pointer_host->proxy,
&sl_locked_pointer_listener,
locked_pointer_host);
} // NOLINT(whitespace/indent)
}

static void sl_pointer_constraints_confine_pointer(struct wl_client* client,
struct wl_resource* resource,
Expand Down Expand Up @@ -170,7 +170,7 @@ static void sl_pointer_constraints_confine_pointer(struct wl_client* client,
zwp_confined_pointer_v1_add_listener(confined_pointer_host->proxy,
&sl_confined_pointer_listener,
confined_pointer_host);
} // NOLINT(whitespace/indent)
}

static struct zwp_pointer_constraints_v1_interface
sl_pointer_constraints_implementation = {
Expand Down
2 changes: 1 addition & 1 deletion sommelier-relative-pointer-manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ static void sl_relative_pointer_manager_get_relative_pointer(
zwp_relative_pointer_v1_add_listener(relative_pointer_host->proxy,
&sl_relative_pointer_listener,
relative_pointer_host);
} // NOLINT(whitespace/indent)
}

static struct zwp_relative_pointer_manager_v1_interface
sl_relative_pointer_manager_implementation = {
Expand Down
8 changes: 4 additions & 4 deletions sommelier-seat.cc
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ static void sl_host_pointer_set_cursor(struct wl_client* client,

wl_pointer_set_cursor(host->proxy, serial,
host_surface ? host_surface->proxy : nullptr, hsx, hsy);
} // NOLINT(whitespace/indent)
}

static void sl_host_pointer_release(struct wl_client* client,
struct wl_resource* resource) {
Expand Down Expand Up @@ -146,7 +146,7 @@ static void sl_pointer_enter(void* data,
if (host->focus_resource)
sl_set_last_event_serial(host->focus_resource, serial);
host->seat->last_serial = serial;
} // NOLINT(whitespace/indent)
}

static void sl_pointer_leave(void* data,
struct wl_pointer* pointer,
Expand Down Expand Up @@ -370,7 +370,7 @@ static void sl_keyboard_enter(void* data,
sl_keyboard_set_focus(host, serial, host_surface, keys);

host->seat->last_serial = serial;
} // NOLINT(whitespace/indent)
}

static void sl_keyboard_leave(void* data,
struct wl_keyboard* keyboard,
Expand Down Expand Up @@ -579,7 +579,7 @@ static void sl_host_touch_down(void* data,
if (host->focus_resource)
sl_set_last_event_serial(host->focus_resource, serial);
host->seat->last_serial = serial;
} // NOLINT(whitespace/indent)
}

static void sl_host_touch_up(void* data,
struct wl_touch* touch,
Expand Down
2 changes: 1 addition & 1 deletion sommelier-shell.cc
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ static void sl_host_shell_get_shell_surface(
wl_shell_surface_add_listener(host_shell_surface->proxy,
&sl_shell_surface_listener, host_shell_surface);
host_surface->has_role = 1;
} // NOLINT(whitespace/indent)
}

static const struct wl_shell_interface sl_shell_implementation = {
sl_host_shell_get_shell_surface};
Expand Down
2 changes: 1 addition & 1 deletion sommelier-subcompositor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ static void sl_subcompositor_get_subsurface(
host->proxy, host_surface->proxy, host_parent->proxy);
wl_subsurface_set_user_data(host_subsurface->proxy, host_subsurface);
host_surface->has_role = 1;
} // NOLINT(whitespace/indent)
}

static const struct wl_subcompositor_interface sl_subcompositor_implementation =
{sl_subcompositor_destroy, sl_subcompositor_get_subsurface};
Expand Down
6 changes: 3 additions & 3 deletions sommelier-text-input.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "sommelier.h" // NOLINT(build/include_directory)
#include "sommelier.h" // NOLINT(build/include_directory)
#include "sommelier-transform.h" // NOLINT(build/include_directory)
#include "weak-resource-ptr.h" // NOLINT(build/include_directory)

Expand Down Expand Up @@ -497,7 +497,7 @@ static void sl_text_input_extension_get_extended_text_input(
zcr_extended_text_input_v1_add_listener(extended_text_input_host->proxy,
&sl_extended_text_input_listener,
extended_text_input_host);
} // NOLINT(whitespace/indent)
}

static void sl_destroy_host_text_input_extension(struct wl_resource* resource) {
struct sl_host_text_input_extension* host =
Expand Down Expand Up @@ -627,7 +627,7 @@ static void sl_text_input_crostini_manager_get_text_input_crostini(
wl_resource_set_implementation(
text_input_crostini_resource, &sl_text_input_crostini_implementation,
host_text_input, sl_destroy_host_text_input_crostini);
} // NOLINT(whitespace/indent)
}

static struct zcr_text_input_crostini_manager_v1_interface
sl_text_input_crostini_manager_implementation = {
Expand Down
4 changes: 2 additions & 2 deletions sommelier-xdg-shell.cc
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ static void sl_xdg_toplevel_show_window_menu(struct wl_client* client,
// Figure out why this was.
xdg_toplevel_shim()->show_window_menu(
host->proxy, host_seat ? host_seat->proxy : nullptr, serial, x, y);
} // NOLINT(whitespace/indent)
}

static void sl_xdg_toplevel_set_app_id(struct wl_client* client,
struct wl_resource* resource,
Expand Down Expand Up @@ -309,7 +309,7 @@ static void sl_xdg_surface_get_popup(struct wl_client* client,

xdg_popup_shim()->add_listener(host_xdg_popup->proxy, &sl_xdg_popup_listener,
host_xdg_popup);
} // NOLINT(whitespace/indent)
}

static void sl_xdg_surface_set_window_geometry(struct wl_client* client,
struct wl_resource* resource,
Expand Down
2 changes: 1 addition & 1 deletion sommelier.cc
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ struct sl_host_buffer* sl_create_host_buffer(struct sl_context* ctx,
host_buffer->is_drm = is_drm;

return host_buffer;
} // NOLINT(whitespace/indent)
}

static void sl_internal_data_offer_destroy(struct sl_data_offer* host) {
TRACE_EVENT("other", "sl_internal_data_offer_destroy");
Expand Down

0 comments on commit 1917175

Please sign in to comment.