class FinLancamentoReceberPage extends StatefulWidget {
  final FinLancamentoReceber finLancamentoReceber;
  final String title;
  final String operacao;

  FinLancamentoReceberPage({this.finLancamentoReceber, this.title, this.operacao, Key key})
      : super(key: key);

  @override
  FinLancamentoReceberPageState createState() => FinLancamentoReceberPageState();
}

class FinLancamentoReceberPageState extends State<FinLancamentoReceberPage>
    with SingleTickerProviderStateMixin {
  TabController _abasController;
  String _estiloBotoesAba = 'iconsAndText';

  // FinLancamentoReceber
  final GlobalKey<FormState> _finLancamentoReceberPersisteFormKey = GlobalKey<FormState>();
  final GlobalKey<ScaffoldState> _finLancamentoReceberPersisteScaffoldKey = GlobalKey<ScaffoldState>();

  @override
  void initState() {
    super.initState();
    atualizarAbas();
    _abasController = TabController(vsync: this, length: getAbasAtivas().length);
    _abasController.addListener(salvarForms);
    ViewUtilLib.paginaMestreDetalheFoiAlterada = false; // vamos controlar as alterações nas paginas filhas aqui para alertar ao usuario sobre possivel perda de dados
  }

  @override
  void dispose() {
    _abasController.dispose();
    super.dispose();
  }

  @override
  Widget build(BuildContext context) {
    return ViewUtilLib.getScaffoldAbaPage(
        widget.title,
        context,
        _abasController,
        getAbasAtivas(),
        getIndicator(),
        _estiloBotoesAba,
        salvarFinLancamentoReceber,
        alterarEstiloBotoes,
        avisarUsuarioAlteracoesNaPagina);
  }

  void atualizarAbas() {
    _todasAsAbas.clear();
	 // a primeira aba sempre é a de Persistencia da tabela Mestre
    _todasAsAbas.add(Aba(
        icon: Icons.receipt,
        text: 'Detalhes',
        visible: true,
        pagina: FinLancamentoReceberPersistePage(
          formKey: _finLancamentoReceberPersisteFormKey,
          scaffoldKey: _finLancamentoReceberPersisteScaffoldKey,
          finLancamentoReceber: widget.finLancamentoReceber,
          atualizaFinLancamentoReceberCallBack: this.atualizarDados,
        )));
    _todasAsAbas.add(Aba(
    	icon: Icons.group,
    	text: 'Relação - Parcela Receber',
    	visible: true,
    	pagina: FinParcelaReceberListaPage(finLancamentoReceber: widget.finLancamentoReceber)));
  }

  void atualizarDados() { // serve para atualizar algum dado após alguma ação numa página filha
    setState(() {
    });
  }

  void salvarForms() {
    // valida e salva o form FinLancamentoReceberDetalhe
    FormState formFinLancamentoReceber = _finLancamentoReceberPersisteFormKey.currentState;
    if (formFinLancamentoReceber != null) {
      if (!formFinLancamentoReceber.validate()) {
        _abasController.animateTo(0);
      } else {
        _finLancamentoReceberPersisteFormKey.currentState?.save();
      }
    }

    // valida e salva os forms OneToOne
  }

  void salvarFinLancamentoReceber() async {
    salvarForms();
    var finLancamentoReceberProvider = Provider.of<FinLancamentoReceberViewModel>(context);
    if (widget.operacao == 'A') {
      await finLancamentoReceberProvider.alterar(widget.finLancamentoReceber);
    } else {
      await finLancamentoReceberProvider.inserir(widget.finLancamentoReceber);
    }
    Navigator.pop(context);
  }

  void alterarEstiloBotoes(String style) {
    setState(() {
      _estiloBotoesAba = style;
    });
  }

  Decoration getIndicator() {
    return ViewUtilLib.getShapeDecorationAbaPage(_estiloBotoesAba);
  }

  Future<bool> avisarUsuarioAlteracoesNaPagina() async {


put(Terrain.HIGH_GRASS,       FLAT_HIGH_GRASS);
		directFlatVisuals.put(Terrain.FURROWED_GRASS,   FLAT_FURROWED_GRASS);

		directFlatVisuals.put(Terrain.STATUE,           FLAT_STATUE);
		directFlatVisuals.put(Terrain.STATUE_SP,        FLAT_STATUE_SP);

		directFlatVisuals.put(Terrain.MINE_CRYSTAL,     FLAT_MINE_CRYSTAL);
		directFlatVisuals.put(Terrain.MINE_BOULDER,     FLAT_MINE_BOULDER);

		directFlatVisuals.put(Terrain.SECRET_DOOR,      directFlatVisuals.get(Terrain.WALL));
	}

	/**********************************************************************
	 * Logic for the selection of alternate tile visuals
	 **********************************************************************/

	public static byte[] tileVariance;

	public static void setupVariance(int size, long seed){
		Random.pushGenerator( seed );

			tileVariance = new byte[size];
			for (int i = 0; i < tileVariance.length; i++) {
				tileVariance[i] = (byte) Random.Int(100);
			}

		Random.popGenerator();
	}

	//These alt visuals will trigger 50% of the time (45% of the time if a rare alt is also present)
	public static SparseArray<Integer> commonAltVisuals = new SparseArray<>();
	static {
		commonAltVisuals.put(FLOOR,                 FLOOR_ALT_1);
		commonAltVisuals.put(GRASS,                 GRASS_ALT);
		commonAltVisuals.put(FLAT_WALL,             FLAT_WALL_ALT);
		commonAltVisuals.put(EMBERS,                EMBERS_ALT);
		commonAltVisuals.put(FLAT_WALL_DECO,        FLAT_WALL_DECO_ALT);
		commonAltVisuals.put(FLOOR_SP,              FLOOR_SP_ALT);
		commonAltVisuals.put(FLOOR_DECO,            FLOOR_DECO_ALT);

		commonAltVisuals.put(FLAT_BOOKSHELF,        FLAT_BOOKSHELF_ALT);
		commonAltVisuals.put(FLAT_HIGH_GRASS,       FLAT_HIGH_GRASS_ALT);
		commonAltVisuals.put(FLAT_FURROWED_GRASS,   FLAT_FURROWED_ALT);
		commonAltVisuals.put(FLAT_MINE_CRYSTAL,     FLAT_MINE_CRYSTAL_ALT);
		commonAltVisuals.put(FLAT_MINE_BOULDER,     FLAT_MINE_BOULDER_ALT);

		commonAltVisuals.put(RAISED_WALL,           RAISED_WALL_ALT);
		commonAltVisuals.put(RAISED_WALL_DECO,      RAISED_WALL_DECO_ALT);
		commonAltVisuals.put(RAISED_WALL_BOOKSHELF, RAISED_WALL_BOOKSHELF_ALT);

		commonAltVisuals.put(RAISED_HIGH_GRASS,     RAISED_HIGH_GRASS_ALT);
		commonAltVisuals.put(RAISED_FURROWED_GRASS, RAISED_FURROWED_ALT);
		commonAltVisuals.put(HIGH_GRASS_OVERHANG,   HIGH_GRASS_OVERHANG_ALT);
		commonAltVisuals.put(FURROWED_OVERHANG,     FURROWED_OVERHANG_ALT);
		commonAltVisuals.put(RAISED_MINE_CRYSTAL,   RAISED_MINE_CRYSTAL_ALT);
		commonAltVisuals.put(RAISED_MINE_BOULDER,   RAISED_MINE_BOULDER_ALT);
		commonAltVisuals.put(HIGH_GRASS_UNDE


    # Generar un video de error para mostrar algo
        try:
            error_path = os.path.join("output", "final_video.mp4")
            os.makedirs(os.path.dirname(error_path), exist_ok=True)
            generate_placeholder_video(
                error_path,
                f"Error al generar el video:\n{str(e)}\nPor favor, inténtalo de nuevo."
            )
        except Exception as err:
            logging.exception(f"Error al crear video de error: {str(err)}")

        return jsonify({"status": "error", "message": str(e)})

@app.route('/video')
def video():
    try:
        return send_file('output/final_video.mp4', mimetype='video/mp4')
    except Exception as e:
        logging.error(f"Error enviando video: {e}")
        return str(e), 404

@app.route('/download')
def download():
    try:
        return send_file(
            'output/final_video.mp4',
            as_attachment=True,
            download_name='video_generado.mp4'
        )
    except Exception as e:
        logging.error(f"Error descargando video: {e}")
        return str(e), 404

@app.route('/progress')
def progress():
    """Endpoint para mostrar el progreso de la generación."""
    try:
        # Verificar si hay un archivo de video
        video_path = os.path.join("output", "final_video.mp4")
        if os.path.exists(video_path):
            status = 100  # Completo
            message = "Video generado exitosamente"
        else:
            status = 50   # En progreso
            message = "Generando video..."

        return jsonify({
            "progress": status,
            "message": message
        })
    except Exception as e:
        logging.exception(f"Error en endpoint progress: {str(e)}")
        return jsonify({
            "progress": 0,
            "message": f"Error: {str(e)}"
        })

if __name__ == '__main__':
    # Importar y aplicar el parche de dashscope una vez al iniciar
    try:
        from dashscope_patch import apply_dashscope_patch
        apply_dashscope_patch()
    except Exception as e:
        logging.error(f"Error al aplicar el parche de dashscope: {str(e)}")

    app.run(debug=False)


.705-1.069.705-.735 1.23-.765 1.369l-.049-.06a9.314 9.314 0 00.239-1.766l.001-.019a.32.32 0 00-.396-.282h.002s-.424-.049-.533.222c-.221.734-.416 1.63-.548 2.547l-.012.104a4.239 4.239 0 01-1.728.761l-.027.004c-.698.007-.626-.442-.626-.442s2.55-.874 1.852-2.595a1.271 1.271 0 00-1.194-.574h.005a1.8 1.8 0 00-1.545 1.236l-.004.013a3.767 3.767 0 00-.292 1.166l-.001.015a1.003 1.003 0 01-.71-.112l.005.003c-.24-.202-.375 0-.375 0s-.42.522 0 .682c.305.106.662.186 1.031.227l.023.002c.107.461.37.847.73 1.11l.005.004c.758.574 2.205-.049 2.205-.049l.596-.33s.018.547.454.626.615.038 1.369-1.796c.442-.938.473-.885.473-.885l.049-.011a9.166 9.166 0 00-.209 2.253v-.013c.131.48.705.435.705.435s.311.09.56-.795c.228-.735.477-1.355.77-1.949l-.035.078h.054a6.323 6.323 0 00.122 2.433l-.009-.043c.32.585 1.158.198 1.158.198a5.79 5.79 0 00.697-.396l-.021.013a2.354 2.354 0 001.683.479l-.01.001a8.677 8.677 0 003.011-.994l-.045.023a1.8 1.8 0 001.537 1.001h.004a2.586 2.586 0 002.056-.699l-.001.001a.769.769 0 00.449.696l.005.002c.465.191.776-.855.776-.855l.776-2.145h.071s.042 1.398.806 1.62a2.518 2.518 0 001.766-.518l-.006.004a.533.533 0 00.198-.543l.001.004zm-21.669.198c.03-1.2.818-1.721 1.087-1.462s.173.825-.342 1.178-.746.286-.746.286zm10.229-4.646s.72-1.864.885-.96-1.5 3.607-1.5 3.607c.169-1.032.383-1.924.653-2.791l-.039.144zm.851 5.19a1.189 1.189 0 01-1.631.732l.007.003a3.48 3.48 0 01.248-1.703l-.009.023c.371-1.241 1.249-.758 1.249-.758s.607.466.135 1.702zm3.172-.544a1.678 1.678 0 01.307-1.152l-.003.005c.413-.758.735-.342.735-.342a.746.746 0 01-.049.961 1.192 1.192 0 01-.989.533z"/></svg>';
  static const String envato =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="21" height="24" preserveAspectRatio="xMidYMid meet" viewBox="0 0 21 24"><path fill="currentColor" d="M17.781.274c-.88-.471-2.922-.327-5.324.383-1.825 1.472-7.76 6.766-7.835 13.348a.49.49 0 01-.94.195l-.001-.003c-.566-1.316-1.026-3.


ecific than we'd like
// with the `.input-group >` part, but without it, we cannot override the sizing.

// stylelint-disable-next-line no-duplicate-selectors
.input-group {
  &:not(.has-validation) {
    > :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu),
    > .dropdown-toggle:nth-last-child(n + 3) {
      @include border-end-radius(0);
    }
  }

  &.has-validation {
    > :nth-last-child(n + 3):not(.dropdown-toggle):not(.dropdown-menu),
    > .dropdown-toggle:nth-last-child(n + 4) {
      @include border-end-radius(0);
    }
  }

  $validation-messages: "";
  @each $state in map-keys($form-validation-states) {
    $validation-messages: $validation-messages + ":not(." + unquote($state) + "-tooltip)" + ":not(." + unquote($state) + "-feedback)";
  }

  > :not(:first-child):not(.dropdown-menu)#{$validation-messages} {
    margin-left: -$input-border-width;
    @include border-start-radius(0);
  }
}
// Breakpoint viewport sizes and media queries.
//
// Breakpoints are defined as a map of (name: minimum width), order from small to large:
//
//    (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px)
//
// The map defined in the `$grid-breakpoints` global variable is used as the `$breakpoints` argument by default.

// Name of the next breakpoint, or null for the last breakpoint.
//
//    >> breakpoint-next(sm)
//    md
//    >> breakpoint-next(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
//    md
//    >> breakpoint-next(sm, $breakpoint-names: (xs sm md lg xl))
//    md
@function breakpoint-next($name, $breakpoints: $grid-breakpoints, $breakpoint-names: map-keys($breakpoints)) {
  $n: index($breakpoint-names, $name);
  @if not $n {
    @error "breakpoint `#{$name}` not found in `#{$breakpoints}`";
  }
  @return if($n < length($breakpoint-names), nth($breakpoint-names, $n + 1), null);
}

// Minimum breakpoint width. Null for the smallest (first) breakpoint.
//
//    >> breakpoint-min(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
//    576px
@function breakpoint-min($name, $breakpoints: $grid-breakpoints) {
  $min: map-get($breakpoints, $name);
  @return if($min != 0, $min, null);
}

// Maximum breakpoint width.
// The maximum value is reduced by 0.02px to work around the limitations of
// `min-` and `max-` prefixes and viewports with fractional widths.
// See https://www.w3.org/TR/mediaqueries-4/#mq-min-max
// Uses 0.02px rather than 0.01px to work around a current rounding bug in Safari.
// See https://bugs.webkit.org/show_bug.cgi?id=178261
//
//    >> breakpoint-max(md, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
//    767.98px
@function breakpoint-max($name, $breakpoints: $grid-breakpoints) {
  $max: map-get($breakpoints, $name);
  @return if($max and $max > 0, $max - .02, null);
}

// Returns a blank string if smallest breakpoint, otherwise returns the name with a dash in front.
//


local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)

function onCreatureAppear(cid)
	npcHandler:onCreatureAppear(cid)
end
function onCreatureDisappear(cid)
	npcHandler:onCreatureDisappear(cid)
end
function onCreatureSay(cid, type, msg)
	npcHandler:onCreatureSay(cid, type, msg)
end
function onThink()
	npcHandler:onThink()
end

local function creatureSayCallback(cid, type, msg)
	if not npcHandler:isFocused(cid) then
		return false
	end

	local player = Player(cid)
	if msgcontains(msg, "jack") then
		if (player:getStorageValue(Storage.TibiaTales.JackFutureQuest.QuestLine) == 5) then
			if
				(player:getStorageValue(Storage.TibiaTales.JackFutureQuest.Mother == 1) and
					(player:getStorageValue(Storage.TibiaTales.JackFutureQuest.Sister)) < 1)
			 then
				npcHandler:say("Why are you asking, he didn't get himself into something again did he?", cid)
				npcHandler.topic[cid] = 1
			end
		end
	elseif msgcontains(msg, "spectulus") then
		if (npcHandler.topic[cid] == 3) then
			npcHandler:say(
				"Spelltolust?! That sounds awfully nasty! What was he doing there - are you telling \z
				me he lived an alternate life and he didn't even tell {mother}?",
				cid
			)
			npcHandler.topic[cid] = 4
		end
	elseif msgcontains(msg, "yes") then
		if (npcHandler.topic[cid] == 1) then
			npcHandler:say(
				{
					"I knew it! He likes taking extended walks outside, leaving all the cleaning to m


333;
}
/* line 571, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform > :nth-child(2) {
  -webkit-transform-origin: 0% 0%;
  background: none;
  content: url(data:image/bmp;base64,Qk08AAAAAAAAADYAAAAoAAAAAQAAAAEAAAABABAAAAAAAAYAAAASCwAAEgsAAAAAAAAAAAAAxhgAAAAA);
}
/* line 578, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-light > * {
  background-color: #eee;
}
/* line 582, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-light > :nth-child(2) {
  content: url(data:image/bmp;base64,Qk08AAAAAAAAADYAAAAoAAAAAQAAAAEAAAABABAAAAAAAAYAAAASCwAAEgsAAAAAAAAAAAAAvXcAAAAA);
}
/* line 588, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-y > * {
  width: 100%;
}
/* line 592, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-y > :first-child {
  height: 3px;
  -webkit-border-top-left-radius: 3px;
  border-top-left-radius: 3px;
  -webkit-border-top-right-radius: 3px;
  border-top-right-radius: 3px;
}
/* line 597, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-y > :nth-child(2) {
  height: 1px;
}
/* line 601, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-y > :last-child {
  height: 3px;
  -webkit-border-bottom-left-radius: 3px;
  border-bottom-left-radius: 3px;
  -webkit-border-bottom-right-radius: 3px;
  border-bottom-right-radius: 3px;
}
/* line 608, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-x > * {
  height: 100%;
}
/* line 612, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core/_layout.scss */
.x-scroll-indicator.csstransform.x-scroll-indicator-x > :first-child {
  width: 3px;
  -webkit-border-top-left-radius: 3px;
  border-top-left-radius: 3px;
  -webkit-border-bottom-left-radius: 3px;
  border-bottom-left-radius: 3px;
}
/* line 617, /Users/jamieavins/git/SDK/touch/resources/themes/stylesheets/sencha-touch/default/core


/config.hpp>           // for LUABIND_API

#ifndef LUABIND_NO_EXCEPTIONS
#include <luabind/error.hpp>            // for error
#include <luabind/exception_handler.hpp>  // for exception_handler_base

#include <luabind/lua_include.hpp>

#include <exception>                    // for exception
#include <stdexcept>                    // for logic_error, runtime_error

namespace luabind { namespace detail {

namespace
{
  exception_handler_base* handler_chain = 0;

  void push_exception_string(lua_State* L, char const* exception, char const* what)
  {
      lua_pushstring(L, exception);
      lua_pushliteral(L, ": '");
      lua_pushstring(L, what);
      lua_pushliteral(L, "'");
      lua_concat(L, 4);
  }
}

void exception_handler_base::try_next(lua_State* L) const
{
    if (next)
        next->handle(L);
    else
        throw;
}

LUABIND_API void handle_exception_aux(lua_State* L)
{
    try
    {
        if (handler_chain)
            handler_chain->handle(L);
        else
            throw;
    }
    catch (error const&)
    {}
    catch (std::logic_error const& e)
    {
        push_exception_string(L, "std::logic_error", e.what());
    }
    catch (std::runtime_error const& e)
    {
        push_exception_string(L, "std::runtime_error", e.what());
    }
    catch (std::exception const& e)
    {
        push_exception_string(L, "std::exception", e.what());
    }
    catch (char const* str)
    {
        push_exception_string(L, "c-string", str);
    }
    catch (...)
    {
        lua_pushliteral(L, "Unknown C++ exception");
    }
}

LUABIND_API void register_exception_handler(exception_handler_base* handler)
{
    if (!handler_chain) handler_chain = handler;
    else
    {
        exception_handler_base* p = handler_chain;

        for (; p->next; p = p->next);

        handler->next = 0;
        p->next = handler;
    }
}

}} // namespace luabind::detail

#endif // LUABIND_NO_EXCEPTIONS
// Copyright (c) 2003 Daniel Wallin and Arvid Norberg

// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:

// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.

// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
// ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
// TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
// SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
// ANY CLAIM, DAMAGES OR OTHER 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.
#include "stdafx.h"
#define LUABIND_BUILDING
#include <luabind/detail/class_rep.hpp>
#include <luabind/detail/format_signature.hpp> // for get_class_name
#include <lu


http://localhost',
    path: '/graphql',
    method: 'GET',
  });

  const introspectedSchema = await loader.load('http://localhost/graphql', {
    method: 'GET',
  });

  const user = introspectedSchema[0].schema.getType('User') as GraphQLObjectType;

  // User
  expect(user.description).toBe('User type it is');
  // User.id
  expect(user.getFields().id.description).toBe('User of ID, of course');
  // Query.user
  expect(schema.getQueryType().getFields().user.description).toBe('Get User by ID');

  done();
});
import { useMemo, useState, useRef } from 'react';

export interface IPagination {
  offset: number
  limit: number
  count: number
}

export const EmptyPagination = () => ({
  offset: 0,
  limit: 50,
  count: 0,
} as IPagination)

/**
 * This hook used for Lsit or Table pagination manage.
 *
 * There are two states inside the hooks: `pagination` and `serverPagination`.
 * `pagination` used for current pagination status,
 * `serverPagination` used for next pagination status returned by the server.
 *
 * To change page, you should call `toNextPage`, `toPrevPage` or `toNthPage` to update offset.
 * To update server returned pagination, you should call `setServerPagination`.
 * @param _pagination initial pagination - Default: `EmptyPagination`
 */
export default function usePagination(_pagination: IPagination = EmptyPagination()) {
  const [pagination, _setPagination] = useState<IPagination>(_pagination)
  const [serverPagination, _setServerPagination] = useState<IPagination>(_pagination)
  const setPagination = useRef(_setPagination).current
  const setServerPagination = useRef(_setServerPagination).current

  const prevOffset = useMemo(() => serverPagination.offset - serverPagination.limit, [serverPagination.offset, serverPagination.limit])
  const nextOffset = useMemo(() => serverPagination.offset + serverPagination.limit, [serverPagination.offset, serverPagination.limit])

  const hasPrevious = useMemo(() => prevOffset >= 0, [prevOffset])
  const hasNext = useMemo(() => nextOffset < serverPagination.count, [nextOffset, serverPagination.count])
  const currentPage = useMemo(
    () => {
      if (serverPagination.offset === 0) return 1
      return serverPagination.offset && serverPagination.limit ? Math.floor(serverPagination.offset / serverPagination.limit) + 1 : 0
    },
    [serverPagination.offset, serverPagination.limit],
  )
  const totalPage = useMemo(() => serverPagination.limit ? Math.ceil(serverPagination.count / serverPagination.limit) : 0, [serverPagination.count, serverPagination.limit])

  const toNextPage = () => {
    setPagination({ offset: nextOffset, limit: serverPagination.limit, count: serverPagination.count })
  }
  const toPrevPage = () => {
    setPagination({ offset: Math.max(0, prevOffset), limit: serverPagination.limit, count: serverPagination.count })
  }
  const toNthPage = (n: number) => {
    setPagination({ offset: Math.min((n-1) * serverPagination.limit, serverPagination.count), limit: serverPagination.limit, count: serverPagination.count })
  }

  return {
    pagination,
    setPagination,
    serverPagination,
    setServerPagination,
    currentPage,
    totalPage,
    toNextPage,
    toPrevPage,
    toNthPage,
    hasPrevious,
    hasNext,
  }
}
import fs from "fs"
import path from "path"
import logger from "../Common/logger";

const MAX


  subscriptionId: NonEmptyString
): TaskEither<ErrorResponses, SubscriptionWithoutKeys> =>
  withApiRequestWrapper(
    logger,
    () => apiClient.getSubscription({ subscriptionId }),
    200
  );

/**
 * Using the **API Manage key** as 'Ocp-Apim-Subscription-Key', the Subscription relating to this key will have a name starting with "MANAGE-"
 * and accordingly no longer equal to the serviceId.
 *
 * Therefore, since it is no longer possible to verify the equality *subscriptionId == serviceId*,
 * it is necessary to verify that the owner of the subscription of the API Key is the same owner of the Subscription to which the ServiceId belongs
 *
 * @param logger
 * @param apiClient
 * @param serviceId
 * @param ownerSubscriptionId subscriptionId related to 'Ocp-Apim-Subscription-Key'
 * @param userId APIM userId
 * @returns
 */
export const serviceOwnerCheckManageTask = (
  logger: ILogger,
  apiClient: APIClient,
  serviceId: NonEmptyString,
  ownerSubscriptionId: NonEmptyString,
  userId: NonEmptyString
): TaskEither<ErrorResponses, NonEmptyString> =>
  pipe(
    getSubscription(logger, apiClient, serviceId),
    TE.chain(serviceSubscription =>
      ownerSubscriptionId.startsWith("MANAGE-")
        ? serviceSubscription.owner_id === userId
          ? TE.of(serviceId)
          : TE.left(ResponseErrorForbiddenNotAuthorized)
        : TE.left(ResponseErrorForbiddenNotAuthorized)
    )
  );
import { Timer } from "../src/timer";
import { TimerStates } from "../src/timer-state";
import { TimerEventTypes } from "../src/timer-event-type";
import { TimerTickData } from "../src/timer-tick-data";
import { TimerEvent } from "../src/timer-event";

describe("Timer", () => {
  let tm: Timer;
  let mockFn: jest.Mock;

  beforeEach(() => {
    tm = new Timer(5000);
    jest.useFakeTimers();
    mockFn = jest.fn();
    console.warn = jest.fn();
  });

  afterEach(() => {
    jest.useRealTimers();
  });

  describe("constructor", () => {
    it("should not throw an error", () => {
      expect(() => {
        return new Timer(3600);
      }).not.toThrow();
    });

    it("should throw an error if duration is not set to a valid number", () => {
      new Timer(-1);

      expect(console.warn).toHaveBeenCalledWith(
        "Timer:duration ~ must be greater than 0, was called with -1",
      );
    });
  });

  describe("properties", () => {
    describe("state", () => {
      describe("the default state", () => {
        it("should be STOPPED", () => {
          expect(tm.state).toBe(TimerStates.STOPPED);
        });
      });

      describe("after calling timer.stop", () => {
        it(" should return TimerStates.STOPPED", () => {
          tm.start();
          tm.stop();
          expect(tm.state).toBe(TimerStates.STOPPED);
        });
      });

      describe("after calling timer.reset", () => {
        it("should return TimerStates.STOPPED", () => {
          tm.start();
          tm.reset();
          expect(tm.state).toBe(TimerStates.STOPPED);
        });
      });

      describe("after calling timer.start", () => {
        it("should return TimerStates.TICKING", () => {
          tm.start();
          expect(tm.state).toBe(TimerStates.TICKING);
        });
      });
    });

    describe("interval", () => {
      it("should get the timer interval value", () => {
        tm = new Timer(1000, 100);
        expect(tm.interval).toBe(100);
      });
    });

    describe("duration", () => {
      it("should thro


return ceil((value / scaleFactor).toDouble()).toInt()
    }

    class Size(
        val width: Int, val height: Int, // TODO this is probably not needed anymore
        private val scaleFactor: Float
    ) {
        override fun equals(other: Any?): Boolean {
            if (this === other) return true
            if (other == null || javaClass != other.javaClass) return false
            val size = other as Size
            if (width != size.width) return false
            return if (height != size.height) false else size.scaleFactor.compareTo(scaleFactor) == 0
        }

        override fun hashCode(): Int {
            var result = width
            result = 31 * result + height
            result = 31 * result + if (scaleFactor != 0.0f) java.lang.Float.floatToIntBits(
                scaleFactor
            ) else 0
            return result
        }

        override fun toString(): String {
            return "Size{" +
                    "width=" + width +
                    ", height=" + height +
                    ", scaleFactor=" + scaleFactor +
                    '}'
        }
    }

    companion object {
        // Bitmap size should be divisible by ROUNDING_VALUE to meet stride requirement.
        // This will help avoiding an extra bitmap allocation when passing the bitmap to RenderScript for blur.
        // Usually it's 16, but on Samsung devices it's 64 for some reason.
        private const val ROUNDING_VALUE = 64
    }
}package com.developments.samu.muteforspotify

import android.content.Intent
import android.net.Uri
import android.os.Bundle
import android.text.InputType
import android.text.InputType.TYPE_NUMBER_FLAG_SIGNED
import android.view.View
import androidx.appcompat.app.AppCompatActivity
import androidx.preference.EditTextPreference
import androidx.preference.Preference
import androidx.preference.PreferenceFragmentCompat
import com.developments.samu.muteforspotify.utilities.AppUtil

class SettingsActivity : AppCompatActivity() {

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.settings_activity)
        if (savedInstanceState == null) {
            supportFragmentManager
                .beginTransaction()
                .replace(R.id.settings, SettingsFragment())
                .commit()
        }
        supportActionBar?.setDisplayHomeAsUpEnabled(true)
    }

    class SettingsFragment : PreferenceFragmentCompat() {
        override fun onCreatePreferences(savedInstanceState: Bundle?, rootKey: String?) {
            setPreferencesFromResource(R.xml.root_preferences, rootKey)
        }

        override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
            super.onViewCreated(view, savedInstanceState)

            this.findPreference<EditTextPreference>(getString(R.string.settings_mute_key))?.apply {
                setOnBindEditTextListener { editText ->
                    editText.inputType = InputType.TYPE_CLASS_NUMBER or TYPE_NUMBER_FLAG_SIGNED
                }
                setOnPreferenceChangeListener { preference, newValue ->
                    with(newValue as String) {
                        isNotBlank()
                        toLongOrNull() != null
                    }
                }
            }

            this.findPreference<EditTextPreference>(getString(R.string.settings_unmute_key))?.apply {
                setOnBindEditTextListener { editText ->
                    editText.inputType = InputType.TYPE_CLASS_NUMBER or TYPE_NUMBER_FLAG_SIGNED
                }
                setOnPreferenceChangeListener { preference, newValue ->


17914b15e78127c89
2024-03-20 09:23:42,314 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Apply patch successful (pred_try)
2024-03-20 09:23:42,318 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Revert patch successful (pred_try)
2024-03-20 09:23:42,318 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Installing with command: . /swe-bench/data/testbeds/claude-2/matplotlib__matplotlib/3.6/tmp09wrm708/miniconda3/bin/activate matplotlib__matplotlib__3.6 && echo 'activate successful' && python -m pip install -e .
2024-03-20 09:24:54,966 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Installation successful
2024-03-20 09:24:54,970 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Apply patch successful (test)
2024-03-20 09:24:54,974 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Apply patch successful (pred)
2024-03-20 09:25:04,775 - INFO - [matplotlib__matplotlib__3.6] [matplotlib__matplotlib-24362] Test script run successful
swe-bench@2f3a6b9fcab2:/swe-bench$
```

### Interpret Results

Then you may interpret the results under `data/logs`, and interpret it following [this guide](https://github.com/princeton-nlp/SWE-bench/blob/main/tutorials/evaluation.md#-metrics).
# Acknowledgements
This application makes use of the following third party libraries:

## AlignedCollectionViewFlowLayout

Copyright (c) 2017 Mischa Hildebrand <web@mischa-hildebrand.de>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
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.

Generated by CocoaPods - https://cocoapods.org
# EwokOS

[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/MisaZhu/ewokos)
[![GitHub commit activity](https://img.shields.io/github/commit-activity/m/MisaZhu/ewokos)](https://github.com/MisaZhu/ewokos/commits/main/)
[![GitHub License](https://img.shields.io/github/license/MisaZhu/ewokos)](https://github.com/


El = (await el.querySelector(
      ".kuc-button__button"
    )) as HTMLButtonElement;
    await expect(
      ["kuc-button__button", "kuc-button__button--alert"].every(c =>
        buttonEl.classList.contains(c)
      )
    ).to.be.true;
  });
});

describe("type prop set to submit successfully", () => {
  const container = new Button({
    type: "normal"
  });
  container.type = "submit";

  it("type prop set to submit successfully", async () => {
    const el = await fixture(container);
    const buttonEl = (await el.querySelector(
      ".kuc-button__button"
    )) as HTMLButtonElement;
    await expect(
      ["kuc-button__button", "kuc-button__button--submit"].every(c =>
        buttonEl.classList.contains(c)
      )
    ).to.be.true;
  });
});

describe("type default prop set to null", () => {
  // @ts-ignore
  const container = new Button({ type: null });

  it("type default prop set to null", async () => {
    const el = await fixture(container);
    const buttonEl = (await el.querySelector(
      ".kuc-button__button"
    )) as HTMLButtonElement;
    await expect(
      ["kuc-button__button", "kuc-button__button--normal"].every(c =>
        buttonEl.classList.contains(c)
      )
    ).to.be.true;
  });
});

describe("type prop set to null", () => {
  const container = new Button({ type: "normal" });
  // @ts-ignore
  container.type = null;

  it("type prop set to null", async () => {
    const el = await fixture(container);
    const buttonEl = (await el.querySelector(
      ".kuc-button__button"
    )) as HTMLButtonElement;
    await expect(
      ["kuc-button__button", "kuc-button__button--normal"].every(c =>
        buttonEl.classList.contains(c)
      )
    ).to.be.true;
  });
});
export class Stream {
  name: string;
  enabled: boolean;  // Requestable
  insureesTracking: number;  // Portion of customers who provide the data now
  newDataAvailable: boolean;  // Whether there is any data collected from tracking insurees

  public static fromResp(data: any): Stream {
    let obj = new Stream();

    obj.name = data.name;
    obj.enabled = data.enabled;
    obj.insureesTracking = data.insureesTracking;
    obj.newDataAvailable = data.newDataAvailable;

    return obj;
  }
}
import { expect } from 'chai';
import { Server } from 'hapi';
import { Container } from 'inversify';
import { SinonStub } from 'sinon';

export const expectIsNotNull = (
  obj: any | null,
): obj is string | number | boolean | object | any[] => {
  expect(obj).to.exist;
  return !!obj;
};

export type MethodStubber<T> = (
  plugin: T,
  kernel: Container,
) => SinonStub | SinonStub[];
export const stubber = <T>(
  methodStubber: MethodStubber<T>,
  injectSymbol: symbol,
  kernel: Container,
) => {
  const instance = kernel.get<T>(injectSymbol);
  const stubs = new Array<SinonStub>().concat(methodStubber(instance, kernel));
  kernel.rebind(injectSymbol).toConstantValue(instance);
  return { instance, stubs };
};

export function makeRequestWithAuthentication(accessToken: string) {
  return (
    server: Server,
    path: string,
    method: 'GET' | 'POST' | 'PATCH' | 'DELETE' = 'GET',
    payload?: object,
  ) =>
    server.inject({
      method,
      url: `http://foo.com${path}`,
      headers: {
        Authorization: `Bearer ${accessToken}


       addButton.text = "+ Add";
            addButton.SetEnabled(true);
            AddElement(inputForm.Q<HashMapItemBase>().Value);
            OnValueChanged?.Invoke(collection);
            Rebuild();
        }

        void CancelInput()
        {
            isInputting = false;

            addButton.text = "+ Add";
            addButton.SetEnabled(true);
            Rebuild();
        }

        // Rebuild GUI contents
        public void Rebuild()
        {
            contents.Clear();
            inputForm.Clear();

            if (collection == null) return;

            var i = 0;
            foreach (var item in (IEnumerable)collection)
            {
                var element = CreateItem(collection, item, "Element " + i);
                element.OnClose += () =>
                {
                    if (isInputting) return;
                    var remove = RemoveElement(item);
                    if (remove)
                    {
                        OnValueChanged?.Invoke(collection);
                        Rebuild();
                    }
                };
                element.Lock();

                contents.Add(element);
                i++;
            }

            if (i == 0)
            {
                var box = new Box();
                box.style.minHeight = EditorGUIUtility.singleLineHeight * 1.2f;
                box.style.paddingLeft = 6f;

                var label = new Label(CollectionTypeName + " is empty.");
                label.style.height = Length.Percent(100f);
                label.style.unityTextAlign = TextAnchor.MiddleLeft;
                box.Add(label);

                inputForm.Add(box);
            }
        }

        public abstract HashMapItemBase CreateItem(object collection, object elementObj, string label);
        public abstract bool CheckElement(object element);
        public abstract object CreateElement();
        public abstract void AddElement(object element);
        public abstract bool RemoveElement(object element);
        public abstract void ClearElements();
        public abstract string CollectionTypeName { get; }

        public abstract class HashMapItemBase : VisualElement
        {
            public Action OnClose;
            public Action<object> OnValueChanged;

            public abstract object Value { get; }
            public abstract void Lock();
        }
    }
}


 the instruction byte in between the command bytes.  This makes the init
// sequences a lot easier to read.

#define I2C_CMD_MODE    0x080

uint8_t u8g_WriteEscSeqP_2_wire(u8g_t *u8g, u8g_dev_t *dev, const uint8_t *esc_seq) {
  uint8_t is_escape = 0;
  uint8_t value;
  for (;;) {
    value = u8g_pgm_read(esc_seq);
    if (is_escape == 0) {
      if (value != 255) {
        if (u8g_WriteByte(u8g, dev, value) == 0 )
          return 0;
        if (u8g_WriteByte(u8g, dev, I2C_CMD_MODE) == 0 )
          return 0;
      }
      else {
        is_escape = 1;
      }
    }
    else {
      if (value == 255) {
        if (u8g_WriteByte(u8g, dev, value) == 0 )
          return 0;
        if (u8g_WriteByte(u8g, dev, I2C_CMD_MODE) == 0 )
          return 0;
      }
      else if (value == 254) {
        break;
      }
      else if (value >= 0x0F0) {
        /* not yet used, do nothing */
      }
      else if (value >= 0xE0 ) {
        u8g_SetAddress(u8g, dev, value & 0x0F);
      }
      else if (value >= 0xD0) {
        u8g_SetChipSelect(u8g, dev, value & 0x0F);
      }
      else if (value >= 0xC0) {
        u8g_SetResetLow(u8g, dev);
        value &= 0x0F;
        value <<= 4;
        value+=2;
        u8g_Delay(value);
        u8g_SetResetHigh(u8g, dev);
        u8g_Delay(value);
      }
      else if (value >= 0xBE) {                       /* not yet implemented */
        /* u8g_SetVCC(u8g, dev, value & 0x01); */
      }
      else if (value <= 127) {
        u8g_Delay(value);
      }
      is_escape = 0;
    }
    esc_seq++;
  }
  return 1;
}

#endif // HAS_GRAPHICAL_LCD
/**
 * Marlin 3D Printer Firmware
 * Copyright (c) 2019 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
 *
 * Based on Sprinter and grbl.
 * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 */

//
// status_screen_DOGM.cpp
// Standard Status Screen for Graphical Display
//

#include "..


4.Ex66.m1.8.8.2.2.2.2.1.3.3">𝑡</ci></apply><apply id="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.1.1"><times id="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.1.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.1"></times><ci id="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.2.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.2">𝑑</ci><ci id="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.3.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.1.1.1.3">𝑥</ci></apply><apply id="S4.Ex66.m1.8.8.2.2.2.2.1.4.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.4"><csymbol cd="latexml" id="S4.Ex66.m1.8.8.2.2.2.2.1.4.1.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.4.1">differential-d</csymbol><ci id="S4.Ex66.m1.8.8.2.2.2.2.1.4.2.cmml" xref="S4.Ex66.m1.8.8.2.2.2.2.1.4.2">𝑡</ci></apply></apply></apply></apply></apply></apply></apply></annotation-xml><annotation encoding="application/x-tex" id="S4.Ex66.m1.8c">\displaystyle\leq\sum^{N}_{i=1}\int^{T}_{0}\left\lvert W^{*}_{i}\left(%
\widetilde{\Pi}_{i}(\mathbf{P}(t),P_{E}(t))\right)-W^{*}_{i}\left(\widetilde{%
\Pi}_{i}(\mathbf{P}^{m}(t),P^{m}_{E}(t))\right)\right\rvert\int_{\overline{%
\mathcal{O}}_{i}}m^{i,n}_{t}(dx)dt</annotation><annotation encoding="application/x-llamapun" id="S4.Ex66.m1.8d">≤ ∑ start_POSTSUPERSCRIPT italic_N end_POSTSUPERSCRIPT start_POSTSUBSCRIPT italic_i = 1 end_POSTSUBSCRIPT ∫ start_POSTSUPERSCRIPT italic_T end_POSTSUPERSCRIPT start_POSTSUBSCRIPT 0 end_POSTSUBSCRIPT | italic_W start_POSTSUPERSCRIPT ∗ end_POSTSUPERSCRIPT start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT ( over~ start_ARG roman_Π end_ARG start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT ( bold_P ( italic


u32,
    /// Reference count
    pub ndm_refcnt: u32,
}

/// Message in response to queuing discipline operations
#[derive(Debug, Size, ToBytes, FromBytesWithInput, Header)]
pub struct Tcmsg {
    /// Family
    pub tcm_family: libc::c_uchar,
    padding_char: libc::c_uchar,
    padding_short: libc::c_ushort,
    /// Interface index
    pub tcm_ifindex: libc::c_int,
    /// Queuing discipline handle
    pub tcm_handle: u32,
    /// Parent queuing discipline
    pub tcm_parent: u32,
    /// Info
    pub tcm_info: u32,
    /// Payload of [`Rtattr`]s
    #[neli(input = "input.checked_sub(Self::header_size()).ok_or(DeError::UnexpectedEOB)?")]
    pub rtattrs: RtBuffer<Tca, Buffer>,
}

impl Tcmsg {
    /// Create a new [`Tcmsg`] structure handling the necessary
    /// padding.
    pub fn new(
        tcm_family: libc::c_uchar,
        tcm_ifindex: libc::c_int,
        tcm_handle: u32,
        tcm_parent: u32,
        tcm_info: u32,
        rtattrs: RtBuffer<Tca, Buffer>,
    ) -> Self {
        Tcmsg {
            tcm_family,
            padding_char: 0,
            padding_short: 0,
            tcm_ifindex,
            tcm_handle,
            tcm_parent,
            tcm_info,
            rtattrs,
        }
    }
}

/// Struct representing route netlink attributes
#[derive(Debug, Size, ToBytes, FromBytes, Header)]
#[neli(header_bound = "T: RtaType")]
#[neli(from_bytes_bound = "T: RtaType")]
#[neli(from_bytes_bound = "P: FromBytesWithInput<Input = usize>")]
#[neli(padding)]
pub struct Rtattr<T, P> {
    /// Length of the attribute
    pub rta_len: libc::c_ushort,
    /// Type of the attribute
    pub rta_type: T,
    /// Payload of the attribute
    #[neli(
        input = "(rta_len as usize).checked_sub(Self::header_size()).ok_or(DeError::UnexpectedEOB)?"
    )]
    pub rta_payload: P,
}

impl<T> Rtattr<T, Buffer>
where
    T: RtaType,
{
    /// Create a new [`Rtattr`].
    pub fn new<P>(_: Option<u16>, rta_type: T, rta_payload: P) -> Result<Self, SerError>
    where
        P: Size + ToBytes,
    {
        let mut attr = Rtattr {
            rta_len: Self::header_size() as u16,
            rta_type,
            rta_payload: Buffer::new(),
        };
        attr.set_payload(&rta_payload)?;
        Ok(attr)
    }

    /// Add a nested attribute to the end of the payload.
    pub fn add_nested_attribute<TT, P>(&mut self, attr: &Rtattr<TT, P>) -> Result<(), SerError>
    where
        TT: RtaType,
        P: ToBytes,
    {
        let mut buffer = Cursor::new(Vec::new());
        attr.to_bytes(&mut buffer)?;

        self.rta_payload.extend_from_slice(buffer.get_ref());
        self.rta_len += buffer.get_ref().len() as u16;
        Ok(())
    }

    /// Return an [`AttrHandle`][crate::attr::AttrHandle] for
    /// attributes nested in the given attribute payload.
    pub fn get_attr_handle<R>(&self) -> Result<RtAttrHandle<R>, DeError>
    where
        R: RtaType


        SocketAddr::from_str(dest_addr)?
    };
    log::info!("mDNS is using {} as dest_addr", addr);

    match mdns_mode {
        MulticastDnsMode::QueryOnly => {
            let conn = DnsConn::server(addr, Config::default())?;
            Ok(Some(Arc::new(conn)))
        }
        MulticastDnsMode::QueryAndGather => {
            let conn = DnsConn::server(
                addr,
                Config {
                    local_names: vec![mdns_name.to_owned()],
                    ..Config::default()
                },
            )?;
            Ok(Some(Arc::new(conn)))
        }
        _ => Ok(None),
    }
}
//! `defmt` global logger over RTT using `rtt-target`

#![no_std]

use core::ptr::NonNull;
use core::sync::atomic::{AtomicBool, Ordering};
use cortex_m::{interrupt, register};
use rtt_target::UpChannel;

static mut CHANNEL: Option<UpChannel> = None;

#[defmt::global_logger]
struct Logger;

impl defmt::Write for Logger {
    fn write(&mut self, bytes: &[u8]) {
        unsafe {
            if let Some(c) = &mut CHANNEL {
                c.write(bytes);
            }
        };
    }
}

pub fn init(channel: UpChannel) {
    unsafe { CHANNEL = Some(channel) }
}

static TAKEN: AtomicBool = AtomicBool::new(false);
static INTERRUPTS_ACTIVE: AtomicBool = AtomicBool::new(false);

unsafe impl defmt::Logger for Logger {
    fn acquire() -> Option<NonNull<dyn defmt::Write>> {
        let primask = register::primask::read();
        interrupt::disable();
        if !TAKEN.load(Ordering::Relaxed) {
            // no need for CAS because interrupts are disabled
            TAKEN.store(true, Ordering::Relaxed);

            INTERRUPTS_ACTIVE.store(primask.is_active(), Ordering::Relaxed);

            Some(NonNull::from(&Logger as &dyn defmt::Write))
        } else {
            if primask.is_active() {
                // re-enable interrupts
                unsafe { interrupt::enable() }
            }
            None
        }
    }

    unsafe fn release(_: NonNull<dyn defmt::Write>) {
        TAKEN.store(false, Ordering::Relaxed);
        if INTERRUPTS_ACTIVE.load(Ordering::Relaxed) {
            // re-enable interrupts
            interrupt::enable()
        }
    }
}
<gh_stars>0
// Copyright 2020 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

use {
    diagnostics_data::Logs,
    diagnostics_hierarchy::assert_data_tree,
    diagnostics_reader::{ArchiveReader, Inspect},
    diagnostics_testing::Severity,
    fuchsia_component::client::ScopedInstance,
    fuchsia_inspect::testing::{assert_inspect_tree, AnyProperty},
    futures::stream::StreamExt,
    log::info,
    std::{collections::HashSet, iter::FromIterator},
};

const DRIVER_COMPONENT: &str =
    "fuchsia-pkg://fuchsia.com/archivist-integration-tests-v2#meta/driver.cm";
const TEST_COMPONENT: &str =
    "fuchsia-pkg://fuchsia.com/archivist-integration-tests-v2#meta/stub_inspect_component.cm";
const TEST_COMPONENT_WITH_CHILDREN: &str =
    "fuchsia-pkg://fuchsia.com/archivist-integration-tests-v2#meta/component_with_children.cm";

#[fuchsi


505f8485f9bebf82b4c28b6363730873c20aeb3f0064bc901925e3a986a845d7239485f959accfcae16\n");
////#else
////    command.set_words_argument(split(words));
////    BX_REQUIRE_FAILURE(command.invoke(output, error));
////    BX_REQUIRE_ERROR(BX_MNEMONIC_TO_SEED_INVALID_IN_LANGUAGES "\n" BX_MNEMONIC_TO_SEED_REQUIRES_ICU "\n");
////#endif
////}
////
////BOOST_AUTO_TEST_CASE(mnemonic_to_seed__invoke__non_ascii_passphrase_and_words_any_spanish__okay_output)
////{
////    BX_DECLARE_COMMAND(mnemonic_to_seed);
////    const std::string words = "previo humilde actuar jarabe tabique ahorro tope pulpo anís señal lavar bahía";
////    command.set_language_option({ "any" });
////    command.set_passphrase_option("博 肉 地 危 惜 多 陪 荒 因 患 伊 基");
////#ifdef WITH_ICU
////    command.set_words_argument(split(to_normal_nfkd_form(words)));
////    BX_REQUIRE_OKAY(command.invoke(output, error));
////    BX_REQUIRE_OUTPUT("f9d7e141ee29670d2b519d60529c3ad79d808fe1ed7b9505f8485f9bebf82b4c28b6363730873c20aeb3f0064bc901925e3a986a845d7239485f959accfcae16\n");
////#else
////    command.set_words_argument(split(words));
////    BX_REQUIRE_FAILURE(command.invoke(output, error));
////    BX_REQUIRE_ERROR(BX_MNEMONIC_TO_SEED_INVALID_IN_LANGUAGES "\n" BX_MNEMONIC_TO_SEED_REQUIRES_ICU "\n");
////#endif
////}
////
////BOOST_AUTO_TEST_CASE(mnemonic_to_seed__invoke__non_ascii_passphrase_and_words_es__okay_output)
////{
////    BX_DECLARE_COMMAND(mnemonic_to_seed);
////    const std::string words = "previo humilde actuar jarabe tabique ahorro tope pulpo anís señal lavar bahía";
////    command.set_language_option({ "es" });
////    command.set_passphrase_option("博 肉 地 危 惜 多 陪 荒 因 患 伊 基");
////#ifdef WITH_ICU
////    command.set_words_argument(split(to_normal_nfkd_form(words)));
////    BX_REQUIRE_OKAY(command.invoke(output, error));
////    BX_REQUIRE_OUTPUT("f9d7e141ee29670d2b519d60529c3ad79d808fe1ed7b9505f8485f9bebf82b4c28b6363730873c20aeb3f0064bc901925e3a986a845d7239485f959accfcae16\n");
////#else
////    command.set_words_argument(split(words));
////    BX_REQUIRE_FAILURE(command.invoke(output, error));
////    BX_REQUIRE_ERROR(BX_MNEMONIC_TO_SEED_INVALID_IN_LANGUAGE "\n");
////#endif
////}
////
////BOOST_AUTO_TEST_CASE(mnemonic_to_seed__invoke__non_ascii_passphrase_and_words_any_frenc


    mul1 = (q31_t) ((q15_t) inA1 * (q15_t) (inB1 >> 16));
    mul4 = (q31_t) ((q15_t) (inA2 >> 16) * (q15_t) inB1);
    mul3 = (q31_t) ((q15_t) inA2 * (q15_t) inB1);

#endif /* #ifndef ARM_MATH_BIG_ENDIAN */

    out1 = (q15_t) __SSAT(mul1 >> 15U, 16);
    out2 = (q15_t) __SSAT(mul2 >> 15U, 16);
    out3 = (q15_t) __SSAT(mul3 >> 15U, 16);
    out4 = (q15_t) __SSAT(mul4 >> 15U, 16);

    *__SIMD32(pCmplxDst)++ = __PKHBT(out1, out2, 16);
    *__SIMD32(pCmplxDst)++ = __PKHBT(out3, out4, 16);

    /* Decrement the numSamples loop counter */
    blkCnt--;
  }

  /* If the numSamples is not a multiple of 4, compute any remaining output samples here.
   ** No loop unrolling is used. */
  blkCnt = numSamples % 0x4U;

  while (blkCnt > 0U)
  {
    /* C[2 * i] = A[2 * i] * B[i].            */
    /* C[2 * i + 1] = A[2 * i + 1] * B[i].        */
    in = *pSrcReal++;
    /* store the result in the destination buffer. */
    *pCmplxDst++ =
      (q15_t) __SSAT((((q31_t) (*pSrcCmplx++) * (in)) >> 15), 16);
    *pCmplxDst++ =
      (q15_t) __SSAT((((q31_t) (*pSrcCmplx++) * (in)) >> 15), 16);

    /* Decrement the numSamples loop counter */
    blkCnt--;
  }

#else

  /* Run the below code for Cortex-M0 */

  while (numSamples > 0U)
  {
    /* realOut = realA * realB.            */
    /* imagOut = imagA * realB.                */
    in = *pSrcReal++;
    /* store the result in the destination buffer. */
    *pCmplxDst++ =
      (q15_t) __SSAT((((q31_t) (*pSrcCmplx++) * (in)) >> 15), 16);
    *pCmplxDst++ =
      (q15_t) __SSAT((((q31_t) (*pSrcCmplx++) * (in)) >> 15), 16);

    /* Decrement the numSamples loop counter */
    numSamples--;
  }

#endif /* #if defined (ARM_MATH_DSP) */

}

/**
 * @} end of CmplxByRealMult group
 */


				next = &__continuation
			}

			return rows, next, nil
		}()
		if err != nil {
			if obj.shouldRetry(err) {
				continue
			}
			return nil, nil, obj.makeErr(err)
		}
		return rows, next, nil
	}

}

func (obj *pgxImpl) All_BucketStorageTally_OrderBy_Desc_IntervalStart(ctx context.Context) (
	rows []*BucketStorageTally, err error) {
	defer mon.Task()(&ctx)(&err)
	if !obj.txn && txutil.IsInsideTx(ctx) {
		panic("using DB when inside of a transaction")
	}

	var __embed_stmt = __sqlbundle_Literal("SELECT bucket_storage_tallies.bucket_name, bucket_storage_tallies.project_id, bucket_storage_tallies.interval_start, bucket_storage_tallies.product_id, bucket_storage_tallies.total_bytes, bucket_storage_tallies.inline, bucket_storage_tallies.remote, bucket_storage_tallies.total_segments_count, bucket_storage_tallies.remote_segments_count, bucket_storage_tallies.inline_segments_count, bucket_storage_tallies.object_count, bucket_storage_tallies.metadata_size FROM bucket_storage_tallies ORDER BY bucket_storage_tallies.interval_start DESC")

	var __values []any

	var __stmt = __sqlbundle_Render(obj.dialect, __embed_stmt)
	obj.logStmt(__stmt, __values...)

	for {
		rows, err = func() (rows []*BucketStorageTally, err error) {
			__rows, err := obj.driver.QueryContext(ctx, __stmt, __values...)
			if err != nil {
				return nil, err
			}
			defer closeRows(__rows, &err)

			for __rows.Next() {
				bucket_storage_tally := &BucketStorageTally{}
				err = __rows.Scan(&bucket_storage_tally.BucketName, &bucket_storage_tally.ProjectId, &bucket_storage_tally.IntervalStart, &bucket_storage_tally.ProductId, &bucket_storage_tally.TotalBytes, &bucket_storage_tally.Inline, &bucket_storage_tally.Remote, &bucket_storage_tally.TotalSegmentsCount, &bucket_storage_tally.RemoteSegmentsCount, &bucket_storage_tally.InlineSegmentsCount, &bucket_storage_tally.ObjectCount, &bucket_storage_tally.MetadataSize)
				if err != nil {
					return nil, err
				}
				rows = append(rows, bucket_storage_tally)
			}
			return rows, nil
		}()
		if err != nil {
			if obj.shouldRetry(err) {
				continue
			}
			return nil, obj.makeErr(err)
		}
		return rows, nil
	}

}

func (obj *pgxImpl) All_BucketStorageTally_By_ProjectId_And_BucketName_And_IntervalStart_GreaterOrEqual_And_IntervalStart_LessOrEqual_OrderBy_Desc_IntervalStart(ctx context.Context,
	bucket_storage_tally_project_id BucketStorageTally_ProjectId_Field,
	bucket_storage_tally_bucket_name BucketStorageTally_BucketName_Field,
	bucket_storage_tally_interval_start_greater_or_equal BucketStorageTally_IntervalStart_Field,
	bucket_storage_tally_interval_start_less_or_equal BucketStorageTally_IntervalStart_Field) (
	rows []*BucketStorageTally, err error) {
	defer mon.Task()(&ctx)(&err)
	if !obj.txn && txutil.IsInsideTx(ctx) {
		panic("using DB when inside of a transaction")
	}

	var __embed_stmt = __sqlbundle_Literal("SELECT bucket_storage_tallies.bucket_name, bucket_storage_tallies.project_id, bucket_storage_tallies.interval_start, bucket_storage_tallies.product_id, bucket_storage_


2%) + `B` (1,49%) + `V` (1,06%)

[rKL]: https://www.reddit.com/r/KeyboardLayouts/
[PGt]: https://getreuer.info/posts/keyboards/alt-layouts/index.html#which-alt-keyboard-layout-should-i-learn

Untuk kelengkapan, saya telah membuat tabel [statistik untuk layout ini dan yang terkait](https://raw.githubusercontent.com/sunaku/enthium/main/stats/):

[cNT]: https://cyanophage.github.io/playground.html?layout=zwdlx-uoyq%5Csnthk%2Caeicbfpgmj%3B.%3D%2F%27vr&mode=ergo&lan=english
[cPM]: https://cyanophage.github.io/playground.html?layout=fpdlx%3Buoybzsnthk%2Caeicqvwgmj-.%27%3D%2F%5Cr&mode=ergo&lan=english
[cNG]: https://cyanophage.github.io/playground.html?layout=byou%27%3Bldwvzciea%2C.htsnqgxjk-%2Frmfp%5C%5E&mode=ergo&lan=english
[cDV]: https://cyanophage.github.io/playground.html?layout=%27%2C.pyfgcrl%2Faoeuidhtns-%3Bqjkxbmwvz%5C%5E&mode=ergo&lan=english
[cCD]: https://cyanophage.github.io/playground.html?layout=qwfpbjluy%3B-arstgmneio%27zxcdvkh%2C.%2F%5C%5E&mode=ergo&lan=english

| Analyzer   | Kategori  | Statistik           | [Enthium][cNT] | [Promethium][cPM] | [Engrammer][cNG] | [Dvorak][cDV] | [Colemak-DH][cCD] |
| ---------- | --------- | ------------------- | -------------- | ----------------- | ---------------- | ------------- | ----------------- |
| Oxey's     | Bigrams   | SFB                 | 0,811%         | 0,868%            | 1,511%           | 2,779%        | 1,367%            |
| Oxey's     | Bigrams   | DSFB                | 6,286%         | 6,761%            | 7,620%           | 6,979%        | 8,767%            |
| Oxey's     | Bigrams   | LSB                 | 0,372%         | 0,404%            | 0,671%           | 1,255%        | 1,975%            |
| Oxey's     | Trigrams  | Inrolls             | 29,442%        | 29,333%           | 28,273%          | 23,820%       | 25,173%           |
| Oxey's     | Trigrams  | Outrolls            | 15,841%        | 14,526%           | 14,050%          | 15,104%       | 20,940%           |
| Oxey's     | Trigrams  | Total Rolls         | 45,283%        | 43,858%           | 42,323%          | 38,924%       | 46,113%           |
| Oxey's     | Trigrams  | Onehands            | 2,348%         | 2,189%            | 2,146%           | 0,624%        | 2,484%            |
| Oxey's     | Trigrams  | Alternates          | 31,877%        | 33,770%           | 32,483%          | 35,769%       | 22,913%           |
| Oxey's     | Trigrams  | Alternates (SFS)    | 7,284%         | 8,205%            | 8,752%           | 8,787%        | 7,461%            |
| Oxey's     | Trigrams


[i % areaColors.length]
                }, areaStyleModel.getAreaStyle()),
                silent: true
            }));
        }
    }
});

/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements.  See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership.  The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License.  You may obtain a copy of the License at
*
*   http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied.  See the License for the
* specific language governing permissions and limitations
* under the License.
*/

/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements.  See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership.  The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License.  You may obtain a copy of the License at
*
*   http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied.  See the License for the
* specific language governing permissions and limitations
* under the License.
*/

var axisBuilderAttrs$3 = [
    'axisLine', 'axisTickLabel', 'axisName'
];
var selfBuilderAttrs$2 = [
    'splitLine', 'splitArea', 'minorSplitLine'
];

AxisView.extend({

    type: 'radiusAxis',

    axisPointerClass: 'PolarAxisPointer',

    render: function (radiusAxisModel, ecModel) {
        this.group.removeAll();
        if (!radiusAxisModel.get('show')) {
            return;
        }
        var radiusAxis = radiusAxisModel.axis;
        var polar = radiusAxis.polar;
        var angleAxis = polar.getAngleAxis();
        var ticksCoords = radiusAxis.getTicksCoords();
        var minorTicksCoords = radiusAxis.getMinorTicksCoords();
        var axisAngle = angleAxis.getExtent()[0];
        var radiusExtent = radiusAxis.getExtent();

        var layout = layoutAxis(polar, radiusAxisModel, axisAngle);
        var axisBuilder = new AxisBuilder(radiusAxisModel, layout);
        each$1(axisBuilderAttrs$3, axisBuilder.add, axisBuilder);
        this.group.add(axisBuilder.getGroup());

        each$1(selfBuilderAttrs$2, function (name) {
            if (radiusAxisModel.get(name + '.show') && !radiusAxis.scale.isBlank()) {
                this['_' + name](radiusAxisModel, polar, axisAngle, radiusExtent, ticksCoords, minorTicksCoords);
            }
        }, this);
    },

    /**
     * @private
     */
    _splitLine: function (radiusAxisModel, polar, axisAngle, radiusExtent, ticksCoords) {
        var splitLineModel = radiusAxisModel.getModel('splitLine');
        var lineStyleModel = splitLineModel.getModel('lineStyle');
        var lineColors = lineStyleModel.get('color');
        var lineCount = 0;

        lineColors = lineColors instanceof Array ? lineColors : [lineColors];

        var splitLines = [];

        for (var i = 0; i < ticksCoords.length; i++) {
            var colorIndex = (lineCount++) % lineColors.length;
            splitLines[colorIndex] = splitLines[colorIndex] || [];
            splitLines[colorIndex].push(new Circle({
                shape: {
                    cx: polar.cx,
                    cy:


 提供了丰富的皮肤和小部件库，用户可以从这些库中选择并安装自己喜欢的皮肤和小部件。同时，Rainmeter 也支持用户编写自定义皮肤和小部件，用户可以利用自己的创造力和设计技能，打造独一无二的桌面界面。

除了个性化的外观，Rainmeter 还提供了一些实用的功能。例如，它可以监控系统资源的使用情况，如 CPU 使用率、内存占用等，帮助用户及时了解电脑的性能状况。此外，Rainmeter 还支持插件扩展，用户可以通过插件实现更多的功能，如日历、邮件通知、社交媒体更新等。

## 跨平台

Rainmeter 是跨平台的，适用于 Windows 操作系统。它支持 Windows XP、Windows Vista、Windows 7、Windows 8 和 Windows 10，同时也支持 32 位和 64 位系统。

Rainmeter 的文件目录构成如下：

- **Rainmeter.exe**：这是 Rainmeter 的可执行文件，用于启动程序。
- **Skins 文件夹**：这个文件夹包含所有的皮肤文件。每个皮肤都有自己的文件夹，其中包含了与皮肤相关的文件，如配置文件、图像和脚本。
- **Plugins 文件夹**：这个文件夹包含一些 Rainmeter 插件，这些插件提供额外的功能和特性，例如读取系统信息、获取天气数据等。
- **Rainmeter.ini**：这是 Rainmeter 的配置文件，用于定义全局设置和默认选项。
- **Rainmeter.log**：这是 Rainmeter 的日志文件，记录了程序的运行情况和错误信息。
- **Rainmeter.sys**：这是 Rainmeter 的系统文件，用于存储一些系统级的信息，如版本号和安装路径。

总之，Rainmeter 是一款功能强大的桌面自定义软件，它为用户提供了丰富的个性化选项，让用户可以根据自己的喜好和需求打造独一无二的桌面环境。无论是美化桌面还是增加实用功能，Rainmeter 都是一个不错的选择。

- [[Rainmeter入门教程-安装和基本使用]]
- [[Rainmeter入门教程-自制小皮肤]]---
uid: 20230601185441
title: Obsidian 主题常见问题
tags: [Obsidian, 主题, 常见问题, BT示例库, Bluetopaz, faq]
description: Obsidian主题常见问题
author: PKMer
type: other
draft


pdate the hashtable entry.
                        rentry->mAssertions = ras->u.as.mInvNext;
                    }
                    as->u.as.mInvNext = nsnull; // for my sanity.
                    break;
                }
                rprev = ras;
                ras = ras->u.as.mInvNext;
            }

            // Wow, it was the _only_ one. Unhash it.
            if (! rentry->mAssertions)
            {
                PL_DHashTableRawRemove(info->mReverseArcs, hdr);
            }

            // add to the list of assertions to unassert
            as->mNext = info->mUnassertList;
            info->mUnassertList = as;

            // Advance to the next assertion
            as = next;
        }
    }

    // if no more assertions exist for this resource, then unhash it.
    if (! entry->mAssertions)
        result = PL_DHASH_REMOVE;

    return result;
}

////////////////////////////////////////////////////////////////////////
// rdfIDataSource methods

class VisitorClosure
{
public:
    VisitorClosure(rdfITripleVisitor* aVisitor) :
        mVisitor(aVisitor),
        mRv(NS_OK)
    {};
    rdfITripleVisitor* mVisitor;
    nsresult mRv;
};

PLDHashOperator PR_CALLBACK
SubjectEnumerator(PLDHashTable* aTable, PLDHashEntryHdr* aHdr,
                  PRUint32 aNumber, void* aArg) {
    Entry* entry = NS_REINTERPRET_CAST(Entry*, aHdr);
    VisitorClosure* closure = NS_STATIC_CAST(VisitorClosure*, aArg);

    nsresult rv;
    nsCOMPtr<nsIRDFNode> subject = do_QueryInterface(entry->mNode, &rv);
    NS_ENSURE_SUCCESS(rv, PL_DHASH_NEXT);

    closure->mRv = closure->mVisitor->Visit(subject, nsnull, nsnull, PR_TRUE);
    if (NS_FAILED(closure->mRv) || closure->mRv == NS_RDF_STOP_VISIT)
        return PL_DHASH_STOP;

    return PL_DHASH_NEXT;
}

NS_IMETHODIMP
InMemoryDataSource::VisitAllSubjects(rdfITripleVisitor *aVisitor)
{
    // Lock datasource against writes
    ++mReadCount;

    // Enumerate all of our entries into an nsISupportsArray.
    VisitorClosure cls(aVisitor);
    PL_DHashTableEnumerate(&mForwardArcs, SubjectEnumerator, &cls);

    // Unlock datasource
    --mReadCount;

    return cls.mRv;
}

class TriplesInnerClosure
{
public:
    TriplesInnerClosure(nsIRDFNode* aSubject, VisitorClosure* aClosure) :
        mSubject(aSubject), mOuter(aClosure) {};
    nsIRDFNode* mSubject;
    VisitorClosure* mOuter;
};

PLDHashOperator PR_CALLBACK
TriplesInnerEnumerator(PLDHashTable* aTable, PLDHashEntryHdr* aHdr,
                  PRUint32 aNumber, void* aArg) {
    Entry* entry = NS_REINTERPRET_CAST(Entry*, aHdr);
    Assertion* assertion = entry->mAssertions;
    TriplesInnerClosure* closure =
        NS_STATIC_CAST(TriplesInnerClosure*, aArg);
    while (assertion) {
        NS_ASSERTION(!assertion->mHashEntry, "shouldn't have to hashes");
        VisitorClosure* cls = closure->mOuter;
        cls->mRv = cls->mVisitor->Visit(closure->mSubject,
                                        assertion->u.as.mProperty,
                                        assertion->u.as.mTarget,
                                        assertion->u.as.mTruthValue);
        if (NS_FAILED(cls->mRv) || cls->mRv == NS_RDF_STOP_VISIT) {
            return PL_DHASH_STOP;
        }
        assertion


)
	},
	[868868440] = {
		model = "metrotrain",
		name = "Freight Train",
		min_dim = v3(-1.702127456665, -5.6679992675781, -0.41772848367691),
		max_dim = v3(1.702127456665, 5.61106300354, 5.1730599403381)
	},
	[3546958660] = {
		model = "mesa2",
		name = "Mesa",
		min_dim = v3(-1.0248398780823, -2.2389166355133, -0.52012646198273),
		max_dim = v3(1.0205800533295, 2.2775979042053, 1.3060536384583)
	},
	[3627815886] = {
		model = "ratloader",
		name = "Bravado Rat-Loader",
		min_dim = v3(-1.0681878328323, -3.0244481563568, -0.20414811372757),
		max_dim = v3(1.0681878328323, 2.4235525131226, 1.661092042923)
	},
	[2634021974] = {
		model = "mamba",
		name = "Mamba",
		min_dim = v3(-0.86749696731567, -2.1331717967987, -0.29572999477386),
		max_dim = v3(0.86749696731567, 1.8285529613495, 0.91106158494949)
	},
	[3105951696] = {
		model = "sandking",
		name = "Sandking XL",
		min_dim = v3(-1.3261500597, -3.5797300338745, -1.0460979938507),
		max_dim = v3(1.3261500597, 3.2591772079468, 1.5201086997986)
	},
	[3080673438] = {
		model = "luxor2",
		name = "Buckingham Luxor Deluxe",
		min_dim = v3(-7.2495946884155, -11.620100975037, -1.6170060634613),
		max_dim = v3(7.2490577697754, 9.134425163269, 3.3290665149689)
	},
	[2014313426] = {
		model = "vetir",
		name = "Vetir",
		min_dim = v3(-1.0968343019485, -3.3882575035095, -1.3317499160767),
		max_dim = v3(1.0968343019485, 3.2654120922089, 2.0637052059174)
	},
	[2551651283] = {
		model = "burrito3",
		name = "Declasse Burrito 2",
		min_dim = v3(-1.2026023864746, -2.835834980011, -0.82858002185822),
		max_dim = v3(1.2026023864746, 2.7137629985809, 1.3024808168411)
	},
	[92612664] = {
		model = "kalahari",
		name = "Kalahari",
		min_dim = v3(-0.86678874492645, -2.1074891090393, -0.52520847320557),
		max_dim = v3(0.86678826808929, 2.0474092960358, 1.1906354427338)
	},
	[3188613414] = {
		model = "jester2",
		name = "Dinka Jester (Racecar)",
		min_dim = v3(-1.0065340995789, -2.3143362998962, -0.23567798733711),
		max_dim =


            application.getString(resource), false
        )
    }

    private fun printSystemInfo() {
        printMessage(String.format("System Info: %s\n", WhisperContext.getSystemInfo()))
    }

    private suspend fun loadData() {
        printMessage("Loading data...\n")
        try {
            copyAssets()
            loadBaseModel()
            canTranscribe = true
        } catch (e: Exception) {
            Log.w(LOG_TAG, e)
            printMessage("${e.localizedMessage}\n")
        }
    }

    private fun printMessage(msg: String) {
        Log.d(LOG_TAG, msg)
    }

    private suspend fun copyAssets() = withContext(Dispatchers.IO) {
        modelsPath?.mkdirs()
        samplesPath?.mkdirs()
        //application.copyData("models", modelsPath, ::printMessage)
        //samplesPath?.let { application.copyData("samples", it, ::printMessage) }
        printMessage("All data copied to working directory.\n")
    }

    private suspend fun loadBaseModel() = withContext(Dispatchers.IO) {
        printMessage("Loading model...\n")
        val models = application.assets.list("models/")
        if (models != null) {
            whisperContext =
                WhisperContext.createContextFromAsset(application.assets, "models/" + models[0])
            printMessage("Loaded model ${models[0]}.\n")
        } else {
            throw Exception("no models found")
        }

        //val firstModel = modelsPath.listFiles()!!.first()
        //whisperContext = WhisperContext.createContextFromFile(firstModel.absolutePath)
    }

    private suspend fun transcribeFile(file: File) {
        if (!canTranscribe) {
            return
        }
        canTranscribe = false
        try {
            currentJob?.cancel()
            printMessage("Reading wave samples... ")
            val data = decodeWaveFile(file)
            transcribeAudio(data)
            currentInputConnection.finishComposingText()
        } catch (e: Exception) {
            Log.w(LOG_TAG, e)
            printMessage("${e.localizedMessage}\n")
        }
    }

    private suspend fun transcribeAudio(data: FloatArray) {
        try {
            printMessage("${data.size / (16000 / 1000)} ms\n")
            val nThreads =
                sharedPref?.getInt(application.getString(R.string.num_threads), maxThreads)
            printMessage("Transcribing data...\n")
            val start = System.currentTimeMillis()
            var text = whisperContext?.transcribeData(data, false, nThreads ?: maxThreads)?.trim()
            printMessage(text.toString())
            // remove special tokens like [MUSIC] or [BLANK_AUDIO]
            // bizarrely, it sometimes also does *music* or (music) so handle these case-s too
            // there's another case with flanking ♪ but it seems slightly different
            text = text?.replace(Regex("""\[[-_a-zA-Z0-9 ]*]"""), "")
            text = text?.replace(Regex("""\*[-_a-zA-Z0-9 ]*\*"""), "")
            text = text?.replace(Regex("""\([-_a-zA-Z0-9 ]*\)"""), "")
            if (checkBoolPref(R.string.casual_mode) == true) {
                printMessage("keeping it casual...\n")
                text = text?.trim()?.lowercase()
                // remove trailing punctuation but not e.g. ! or ?
                if (text?.length!! > 0 && text[text.lastIndex] in charArrayOf('.', ',', ';')) {
                    // < makes the range exclusive instead of inclusive, dropping the last char
                    text = text.slice(0..<text.lastIndex)
                }
            }
            // add text only if non-empty
            // avoids adding just a single space for empty messages
            if (text?.length!! > 0) {
                currentInputConnection.setComposingText(text + (trailing ?: ""), 1)
            }
            val elapsed = System.currentTimeMillis() - start
            printMessage("Done ($elapsed ms): \n$text\n")
        } catch (e: Except


{{ user.place_of_birth }}

                    Update Profile
                    <button class="btn waves-effect waves-light red delete-account-btn">Delete Account</button>

Confirm Account Deletion

Are you sure you want to delete your account? This action cannot be undone.

Please type DELETE to confirm.

            <input type="text" id="delete-account-confirmation" placeholder="Type DELETE to confirm">

            <button id="confirm-delete-account-btn" class="modal-close waves-effect waves-green btn-flat" disabled>Delete</button>
            <button class="modal-close waves-effect waves-red btn-flat">Cancel</button>

{% endblock %}<!DOCTYPE html>
{% load django_bootstrap5 %}
{% load i18n %}
{% get_current_language as LANGUAGE_CODE %}
{% bootstrap_setting "color_mode" as COLOR_MODE %}
{% bootstrap_setting "javascript_in_head" as BOOTSTRAP_JAVASCRIPT_IN_HEAD %}

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

    <title>{% block bootstrap5_title %}django-bootstrap5 template title{% endblock %}</title>

    {% bootstrap_css %}

    {% if BOOTSTRAP_JAVASCRIPT_IN_HEAD %}{% bootstrap_javascript %}{% endif %}

  {% block bootstrap5_extra_head %}{% endblock %}

{% block bootstrap5_before_content %}{% endblock %}
{% block bootstrap5_content %} CONTENT {% endblock %}
{% block bootstrap5_after_content %}{% endblock %}

{% if not BOOTSTRAP_JAVASCRIPT_IN_HEAD %}{% bootstrap_javascript %}{% endif %}

{% block bootstrap5_extra_script %}{% endblock %}

{% extends "admin/base_site.html" %}
{% load i18n %}

{% block breadcrumbs %}

{% translate 'Home' %}
› {% translate 'Documentation' %}
› {% translate 'Bookmarklets' %}

{% endblock %}
{% block title %}{% translate "Documentation bookmarklets" %}{% endblock %}

{% block content %}

{% blocktranslate trimmed %}
To install bookmarklets, drag the link to your bookmarks toolbar, or right-click
the link and add it to your bookmarks. Now you can select the bookmarklet
from any page in the site.
{% endblocktranslate %}

<a href="javascript:(function(){if(typeof XMLHttpRequest!='undefined'){x=new XMLHttpRequest()}else{return;}x.open('HEAD',location.href,false);x.send(null);try{view=x.getResponseHeader('x-view');}catch(e){alert('No view found for this


ubparsers.add_parser('keep_markers', help='Keep markers from JSON file, others will be removed')
    keep_markers_parser.add_argument('--in_json', help="Path to input JSON file")
    keep_markers_parser.add_argument('--markers', help="Path to file with markers to keep (1 per line)")
    keep_markers_parser.add_argument('--out_json', help="Path to output JSON file")

    args = parser.parse_args()

    if args.function == 'transform_pkl_to_json':
        transform_pkl_to_json(Path(args.pkl), Path(args.json))
    elif args.function == 'transform_json_to_pkl':
        transform_json_to_pkl(Path(args.json), Path(args.pkl))
    elif args.function == 'add_marker':
        add_marker(
            args.in_json,
            args.out_json,
            args.name,
            args.m_length,
            args.g_length,
            args.gca,
            args.k_name,
            args.k_id,
            args.p_name,
            args.p_id,
            args.c_name,
            args.c_id,
            args.o_name,
            args.o_id,
            args.f_name,
            args.f_id,
            args.g_name,
            args.g_id,
            args.s_name,
            args.s_id,
            args.t_name)
    elif args.function == 'remove_markers':
        remove_markers(args.in_json, args.markers, args.out_json, args.kept_markers)
    elif args.function == 'keep_markers':
        keep_markers(args.in_json, args.markers, args.out_json)


S";       break;
      case 6: lines_desc = "CLK | CS";        break;
      case 7: lines_desc = "DATA | CLK | CS"; break;
      }
    Msg(MSGT_DEBUG, "At PC=%04X: 93c46: Set Lines %s", CPU_GetPC, lines_desc);
    }
  #endif

  /* CS Line (Reset), 1->0 edge */
  if (!(lines & EEPROM_93C46_LINE_CS))
     {
     if (EEPROM_93c46.Lines & EEPROM_93C46_LINE_CS)
        {
        EEPROM_93c46_Init (EEPROM_93C46_INIT_NORMAL);
        }
     EEPROM_93c46.Lines = (EEPROM_93c46.Lines & ~0x07) | (lines & 0x07)
                        | EEPROM_93C46_LINE_DATA_OUT;
     return;
     }

  /* Clock Line, 0->1 edge */
  /* (This is the big part) */
  if ((lines & EEPROM_93C46_LINE_CLOCK) && !(EEPROM_93c46.Lines & EEPROM_93C46_LINE_CLOCK))
     {
     byte   data = lines & EEPROM_93C46_LINE_DATA_IN;
     EEPROM_93c46.Lines = (EEPROM_93c46.Lines & ~0x07) | (lines & 0x07);
     switch (EEPROM_93c46.Status)
       {
       // Start Bit ------------------------------------------------------------
       case EEPROM_93C46_STATUS_START:
            if (data)
               {
               #ifdef DEBUG_EEPROM
                  Msg(MSGT_DEBUG, "At PC=%04X: 93c46: START", CPU_GetPC);
               #endif
               EEPROM_93c46.Status = EEPROM_93C46_STATUS_OPCODE;
               EEPROM_93c46.Opcode = 0x0000;
               EEPROM_93c46.Position = 0;
               }
            return;
       // Opcode (2 Bits) + Address (6 Bits) Read ------------------------------
       case EEPROM_93C46_STATUS_OPCODE:
            EEPROM_93c46.Opcode = (EEPROM_93c46.Opcode << 1) | data;
            if (++EEPROM_93c46.Position == 8)
               {
               #ifdef DEBUG_EEPROM
                  char bitfield[9];
                  StrWriteBitfield (EEPROM_93c46.Opcode, 8, bitfield);
                  Msg(MSGT_DEBUG, "At PC=%04X: 93c46: OPCODE = %s", CPU_GetPC, bitfield);
               #endif
               switch (EEPROM_93c46.Opcode & 0xC0)
                 {
                 case 0x00: // 00: EXTENDED ------------------------------------
                      switch (EEPROM_93c46.Opcode & 0x30)
                        {
                        case 0x00: // 00: ERASE/WRITE DISABLE ------------------
                             #ifdef DEBUG_EEPROM
                                Msg(MSGT_DEBUG, "At PC=%04X: 93c46: E/W DISABLE", CPU_GetPC);
                             #endif
                             EEPROM_93c46.Read_Only = TRUE;
                             EEPROM_93c46.Status = EEPROM_93C46_STATUS_START;
                             return;
                        case 0x10: // 00: WRITE ALL ----------------------------
                             #ifdef DEBUG_EEPROM
                                Msg(MSGT_DEBUG, "At PC=%04X: 93c46: WRITE ALL", CPU_GetPC);
                             #endif
                             EEPROM_93c46.Position = 0;
                             EEPROM_93c46.Latch = 0x0000;
                             EEPROM_93c46.Status = EEPROM_93C46_STATUS_WRITING;


汗流如雨玉，不題吉安而來父親回衙" +
                        ".玉，不題汗流如雨吉安而來冒認收了父親回衙.關雎誨曰：去.父親回衙冒認收了吉安而來.饒爾去罷」也懊悔不了，愈聽愈惱此是後話" +
                        ".以測機不稱讚樂而不淫第十一回建章曰：.第三回」第二回第六回誨出了」第十回耳矣.出矣誨覽關雎」去事.也懊悔不了，愈聽愈惱饒爾去罷」" +
                        ".第二回覽矣第一回」第七回相域誨意第八回去出.驚異意招」出第二回德泉淹第十回關雎覽第四回誨曰：.也懊悔不了事饒爾去罷」誨」此是後話出矣去覽意" +
                        ".曰：出，可意意矣去出誨關雎耳.饒爾去罷」此是後話也懊悔不了，愈聽愈惱.曰：」耳去事矣關雎出.去意出，可.曰：耳」事.耳覽去曰：矣事」意" +
                        ".不稱讚樂而不淫在一處己轉身.第二回第九回第七回.第九回第二回第八回羨殺第六回.第四回第二回第五回羨殺.汗流如雨玉，不題吉安而來父親回衙" +
                        ".玉，不題汗流如雨吉安而來冒認收了父親回衙.關雎誨曰：去.父親回衙冒認收了吉安而來.饒爾去罷」也懊悔不了，愈聽愈惱此是後話" +
                        ".以測機不稱讚樂而不淫第十一回建章曰：.第三回」第二回第六回誨出了」第十回耳矣.出矣誨覽關雎」去事.也懊悔不了，愈聽愈惱饒爾去罷」" +
                        ".第二回覽矣第一回」第七回相域誨意第八回去出.驚異意招」出第二回德泉淹第十回關雎覽第四回誨曰：.也懊悔不了事饒爾去罷」誨」此是後話出矣去覽意" +
                        ".曰：出，可意意矣去出誨關雎耳.饒爾去罷」此是後話也懊悔不了，愈聽愈惱.曰：」耳去事矣關雎出.去意出，可.曰：耳」事.耳覽去曰：矣事」意" +
                        ".不稱讚樂而不淫在一處己轉身.第二回第九回第七回.第九回第二回第八回羨殺第六回.第四回第二回第五回羨�


otosFact; }
    const Fact*     _stopTakingVideo        (void) const final { return &_stopTakingVideoFact; }
    void            _calcGlideSlope         (void) final { };
    MissionItem*    _createLandItem         (int seqNum, bool altRel, double lat, double lon, double alt, QObject* parent) final;

    QMap<QString, FactMetaData*> _metaDataMap;

    Fact            _landingDistanceFact;
    Fact            _finalApproachAltitudeFact;
    Fact            _useDoChangeSpeedFact;
    Fact            _finalApproachSpeedFact;
    Fact            _loiterRadiusFact;
    Fact            _loiterClockwiseFact;
    Fact            _landingHeadingFact;
    Fact            _landingAltitudeFact;
    Fact            _useLoiterToAltFact;
    Fact            _stopTakingPhotosFact;
    Fact            _stopTakingVideoFact;

    friend class LandingComplexItemTest;
};


"chou": "筹抽绸酬愁丑臭仇畴稠瞅踌惆俦瘳雠帱", "qiu": "求球秋丘邱仇酋裘龟囚遒鳅虬蚯泅楸湫犰逑巯艽俅蝤赇鼽糗", "xiu": "修秀休宿袖绣臭朽锈羞嗅岫溴庥馐咻髹鸺貅", "chu": "出处础初助除储畜触楚厨雏矗橱锄滁躇怵绌搐刍蜍黜杵蹰亍樗憷楮", "tuan": "团揣湍疃抟彖", "zhui": "追坠缀揣椎锥赘惴隹骓缒", "chuan": "传川船穿串喘椽舛钏遄氚巛舡", "zhuan": "专转传赚砖撰篆馔啭颛", "yuan": "元员院原源远愿园援圆缘袁怨渊苑宛冤媛猿垣沅塬垸鸳辕鸢瑗圜爰芫鼋橼螈眢箢掾", "cuan": "窜攒篡蹿撺爨汆镩", "chuang": "创床窗闯幢疮怆", "zhuang": "装状庄壮撞妆幢桩奘僮戆", "chui": "吹垂锤炊椎陲槌捶棰", "chun": "春纯醇淳唇椿蠢鹑朐莼肫蝽", "zhun": "准屯淳谆肫窀", "cu": "促趋趣粗簇醋卒蹴猝蹙蔟殂徂", "dun": "吨顿盾敦蹲墩囤沌钝炖盹遁趸砘礅", "qu": "区去取曲趋渠趣驱屈躯衢娶祛瞿岖龋觑朐蛐癯蛆苣阒诎劬蕖蘧氍黢蠼璩麴鸲磲", "xu": "需许续须序徐休蓄畜虚吁绪叙旭邪恤墟栩絮圩婿戌胥嘘浒煦酗诩朐盱蓿溆洫顼勖糈砉醑", "chuo": "辍绰戳淖啜龊踔辶", "zu": "组族足祖租阻卒俎诅镞菹", "ji": "济机其技基记计系期际及集级几给积极己纪即继击既激绩急奇吉季齐疾迹鸡剂辑籍寄挤圾冀


16)  +\idx)]
    ldr sAmi, [input_addr, 8*(\num*(16+1)+\idx)]
    ldr sAmo, [input_addr, 8*(\num*(18)  +\idx)]
    ldr sAmu, [input_addr, 8*(\num*(18+1)+\idx)]
    ldr sAsa, [input_addr, 8*(\num*(20)  +\idx)]
    ldr sAse, [input_addr, 8*(\num*(20+1)+\idx)]
    ldr sAsi, [input_addr, 8*(\num*(22)  +\idx)]
    ldr sAso, [input_addr, 8*(\num*(22+1)+\idx)]
    ldr sAsu, [input_addr, 8*(\num*(24)  +\idx)]
.endm

#define STACK_LOCS 40

#define STACK_SIZE (16*6 + 8*8 + 6*8 + (STACK_LOCS) * 8)
#define STACK_BASE_GPRS (6*8)
#define STACK_BASE_VREGS (6*8 + 16*6)
#define STACK_OFFSET_LOCS (16*6 + 8*8 + 6*8)

#define STACK_OFFSET_INPUT (0*8)
#define STACK_OFFSET_CONST_SCALAR (1*8)
#define STACK_OFFSET_CONST_VECTOR (2*8)
#define STACK_OFFSET_COUNT (3*8)
#define STACK_OFFSET_OUTER (4*8)

#define STACK_LOC_0 ((STACK_OFFSET_LOCS) + 0*8)
#define STACK_LOC_1 ((STACK_OFFSET_LOCS) + 1*8)
#define STACK_LOC_2 ((STACK_OFFSET_LOCS) + 2*8)
#define STACK_LOC_3 ((STACK_OFFSET_LOCS) + 3*8)
#define STACK_LOC_4 ((STACK_OFFSET_LOCS) + 4*8)
#define STACK_LOC_5 ((STACK_OFFSET_LOCS) + 5*8)
#define STACK_LOC_6 ((STACK_OFFSET_LOCS) + 6*8)
#define STACK_LOC_7 ((STACK_OFFSET_LOCS) + 7*8)
#define STACK_LOC_8 ((STACK_OFFSET_LOCS) + 8*8)
#define STACK_LOC_9 ((STACK_OFFSET_LOCS) + 9*8)
#define STACK_LOC_10 ((STACK_OFFSET_LOCS) + 10*8)
#define STACK_LOC_11 ((STACK_OFFSET_LOCS) + 11*8)
#define STACK_LOC_12 ((STACK_OFFSET_LOCS) + 12*8)
#define STACK_LOC_13 ((STACK_OFFSET_LOCS) + 13*8)
#define STACK_LOC_14 ((STACK_OFFSET_LOCS) + 14*8)
#define STACK_LOC_15 ((STACK_OFFSET_LOCS) + 15*8)
#define STACK_LOC_16 ((STACK_OFFSET_LOCS) + 16*8)
#define STACK_LOC_17 ((STACK_OFFSET_LOCS) + 17*8)
#define STACK_LOC_18 ((STACK_OFFSET_LOCS) + 18*8)
#define STACK_LOC_19 ((STACK_OFFSET_LOCS) + 19*8)
#define STACK_LOC_20 ((STACK_OFFSET_LOCS) + 20*8)
#define STACK_LOC_21 ((STACK_OFFSET_LOCS) + 21*8)
#define STACK_LOC_22 ((STACK_OFFSET_LOCS) + 22*8)
#define STACK_LOC_23 ((STACK_OFFSET_LOCS) + 23*8)
#define STACK_LOC_24 ((STACK_OFFSET_LOCS) + 24*8)
#define STACK_LOC_25 ((STACK_OFFSET_LOCS) + 25*8)
#define STACK_LOC_26 ((STACK_OFFSET_LOC


        VirtualClickType.NUMBER_KEY -> {
                        // 刷新背包物品
                        sendSlotChange(inventory.size + 27 + buttonNum, inventory.getStorageItem(27 + buttonNum))
                    }
                    // F 键
                    VirtualClickType.SWAP_OFFHAND -> {
                        // 刷新副手物品
                        viewer.inventory.setItemInOffHand(viewer.inventory.itemInOffHand)
                    }
                    // SHIFT 键
                    VirtualClickType.SHIFT_LEFT, VirtualClickType.SHIFT_RIGHT -> {
                        // 获取点击物品数量
                        var amount = clickItem.amount
                        // 从页面移动到背包
                        if (slotNum < inventory.size) {
                            // 从最后一个物品开始检索
                            for (i in 35 downTo 0) {
                                val item = inventory.getStorageItem(i)
                                if (item.isAir) {
                                    // 刷新背包物品
                                    sendSlotChange(inventory.size + i, item)
                                    break
                                }
                                if (item.isSimilar(clickItem)) {
                                    // 扣除物品数量
                                    amount -= item.type.maxStackSize - item.amount
                                    // 刷新背包物品
                                    sendSlotChange(inventory.size + i, item)
                                }
                                if (amount <= 0) {
                                    break
                                }
                            }
                        }
                        // 从物品栏移动到页面
                        else {
                            // 从第一个物品开始检索
                            for (i in 0 until inventory.size) {
                                val item = inventory.getItem(i)
                                if (item.isAir) {
                                    // 刷新页面物品
                                    sendSlotChange(i, item ?: air)
                                    break
                                }
                                if (item!!.isSimilar(clickItem)) {
                                    // 扣除物品数量
                                    amount -= item.type.maxStackSize - item.amount
                                    // 刷新页面物品
                                    sendSlotChange(i, item)
                                }
                            }
                        }
                    }
                    // 其他暂时不管
                    else -> {}
                }
            }
        }
    }
}

// 1.19

private typealias NMSPacketPlayOutOpenWindow = net.minecraft.network.protocol.game.PacketPlayOutOpenWindow

private typealias NMSPacketPlayOutWindowItems = net.minecraft.network.protocol.game.PacketPlayOutWindowItems

private typealias NMSPacketPlayOutSetSlot = net.minecraft.network.protocol.game.PacketPlayOutSetSlot

private typealias NMSPacketPlayOutSetCursorItem = net.minecraft.network.protocol.game.ClientboundSetCursorItemPacket

private typealias NMSPacketPlayOutWindowData = net.minecraft.network.protocol.game.PacketPlayOutWindowData

private typealias NMSPacketPlayOutCloseWindow = net.minecraft.network.protocol.game.PacketPlayOutCloseWindow

private typealias NMSIChatBaseComponent = net.minecraft.network.chat.IChatBaseComponent

private typealias NMSItemStack = net.minecraft.world.item.ItemStack

private typealias NMSNonNullList<T> = net.minecraft.core.NonNullList<T>

private typealias Craft19ChatMessage = org.bukkit.craftbukkit.v1_19_R3.util.CraftChatMessage

private typealias Craft19Container = org.bukkit.craftbukkit.v1_19_R3.inventory.CraftContainer

private typealias Craft19ItemStack = org.bukkit.craftbukkit.v1_19_R3.inventory.CraftItemStack

private typealias Craft19Player


327-1.497.174-2.57 1.46-2.57 2.93V21.75a.75.75 0 001.029.696l3.471-1.388 3.472 1.388a.75.75 0 00.556 0l3.472-1.388 3.471 1.388a.75.75 0 001.029-.696V4.757c0-1.47-1.073-2.756-2.57-2.93A49.255 49.255 0 0012 1.5Zm-.97 6.53a.75.75 0 10-1.06-1.06L7.72 9.22a.75.75 0 000 1.06l2.25 2.25a.75.75 0 101.06-1.06l-.97-.97h3.065a1.875 1.875 0 010 3.75H12a.75.75 0 000 1.5h1.125a3.375 3.375 0 100-6.75h-3.064l.97-.97Z" clip-rule="evenodd"/></svg>';
  static const String rectangle_group =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="24" height="24" preserveAspectRatio="xMidYMid meet" viewBox="0 0 24 24"><path fill="currentColor" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M2.25 7.125C2.25 6.504 2.754 6 3.375 6h6c.621 0 1.125.504 1.125 1.125v3.75c0 .621-.504 1.125-1.125 1.125h-6a1.125 1.125 0 01-1.125-1.125v-3.75Zm12 1.5c0-.621.504-1.125 1.125-1.125h5.25c.621 0 1.125.504 1.125 1.125v8.25c0 .621-.504 1.125-1.125 1.125h-5.25a1.125 1.125 0 01-1.125-1.125v-8.25Zm-10.5 7.5c0-.621.504-1.125 1.125-1.125h5.25c.621 0 1.125.504 1.125 1.125v2.25c0 .621-.504 1.125-1.125 1.125h-5.25a1.125 1.125 0 01-1.125-1.125v-2.25Z"/></svg>';
  static const String rectangle_group_20_solid =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="20" height="20" preserveAspectRatio="xMidYMid meet" viewBox="0 0 20 20"><path fill="currentColor" fill-rule="evenodd" d="M2.5 3A1.5 1.5 0 001 4.5v4A1.5 1.5 0 002.5 10h6A1.5 1.5 0 0010 8.5v-4A1.5 1.5 0 008.5 3h-6Zm11 2A1.5 1.5 0 0012 6.5v7a1.5 1.5 0 001.5 1.5h4a1.5 1.5 0 001.5-1.5v-7A1.5 1.5 0 0017.5 5h-4Zm-10 7A1.5 1.5 0 002 13.5v2A1.5 1.5 0 003.5 17h6a1.5 1.5 0 001.5-1.5v-2A1.5 1.5 0 009.5 12h-6Z" clip-rule="evenodd"/></svg>';
  static const String rectangle_group_solid =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="24" height="24" preserveAsp


ny bugs if emulation
     via /proc/self/fd doesn't check for empty names.  */
  ASSERT (chdir ("..") == 0);
  ASSERT (close (dfd) == 0);
  dfd = open (".", O_RDONLY);
  ASSERT (0 <= dfd);

  ASSERT (close (creat (BASE "sub2/file", 0600)) == 0);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "sub1", dfd, BASE "sub2", 0) == -1);
  ASSERT (errno == EEXIST || errno == ENOTEMPTY);
  ASSERT (unlink (BASE "sub2/file") == 0);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "sub2", dfd, BASE "sub1/.", 0) == -1);
  ASSERT (errno == EINVAL || errno == EISDIR || errno == EBUSY
          || errno == ENOTEMPTY || errno == EEXIST
          || errno == ENOENT /* WSL */);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "sub2/.", dfd, BASE "sub1", 0) == -1);
  ASSERT (errno == EINVAL || errno == EBUSY || errno == EEXIST
          || errno == ENOENT /* WSL */);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "17", dfd, BASE "sub1", 0) == -1);
  ASSERT (errno == EISDIR);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "nosuch", dfd, BASE "18", 0) == -1);
  ASSERT (errno == ENOENT);
  errno = 0;
  ASSERT (renameatu (dfd, "", dfd, BASE "17", 0) == -1);
  ASSERT (errno == ENOENT);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "17", dfd, "", 0) == -1);
  ASSERT (errno == ENOENT);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "sub2", dfd, BASE "17", 0) == -1);
  ASSERT (errno == ENOTDIR);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "17/", dfd, BASE "18", 0) == -1);
  ASSERT (errno == ENOTDIR);
  errno = 0;
  ASSERT (renameatu (dfd, BASE "17", dfd, BASE "18/", 0) == -1);
  ASSERT (errno == ENOTDIR || errno == ENOENT);

  /* Finally, make sure we cannot overwrite existing files.  */
  ASSERT (close (creat (BASE "sub2/file", 0600)) == 0);
  errno = 0;
  ASSERT ((renameatu (dfd, BASE "sub2/file", dfd, BASE "sub2/file",
                      RENAME_NOREPLACE)
           == -1)
          && errno == EEXIST);
  errno = 0;
  ASSERT ((renameatu (dfd, BASE "sub2", dfd, BASE "sub2", RENAME_NOREPLACE)
           == -1)
          && errno == EEXIST);
  errno = 0;
  ASSERT ((renameatu (dfd, BASE "sub2", dfd, BASE "sub1", RENAME_NOREPLACE)
           == -1)
          && errno == EEXIST);
  errno = 0;
  ASSERT ((renameatu (dfd, BASE "sub2/file", dfd, BASE "17", RENAME_NOREPLACE)
           == -1)
          && errno == EEXIST);

  errno = 0;
  ASSERT (renameatu (dfd, BASE "sub2", dfd, BASE "sub1", RENAME_EXCHANGE) < 0
          ? errno == EINVAL || errno == ENOSYS || errno == ENOTSUP
          : (renameatu (dfd, BASE "sub1/file", dfd, BASE "sub2/file",
                        RENAME_NOREPLACE)
             == 0));

  /* Cleanup.  */
  ASSERT (close (dfd) == 0);
  ASSERT (unlink (BASE "sub2/file") == 0);
  ASSERT (unlink (BASE "17") == 0);
  ASSERT (rmdir (BASE "sub1") == 0);
  ASSERT (rmdir (BASE "sub2") == 0);
  free (cwd);

  if (result == 77)
    fputs ("skipping test: symlinks not supported on this file system\n",
           stderr);
  return (result ? result : test_exit_status);
}


 have no access
    // to the augmented setter, augmenting setters have no access to the
    // augmented getters, and augmenting fields only have read access to the
    // augmented field initializer expression.
    return new IfNullSet(
        _createRead(), _createWrite(offset, value, forEffect: voidContext),
        forEffect: voidContext)
      ..fileOffset = offset;
  }

  @override
  Generator buildIndexedAccess(Expression index, Token token,
      {required bool isNullAware}) {
    // TODO(johnniwinther): The semantics is unclear. Is this accessing the
    // invoke target, which must be an `operator []` or the read target with a
    // type that has an `operator []`.
    throw new UnimplementedError();
  }

  @override
  Expression buildPostfixIncrement(Name binaryOperator,
      {int offset = TreeNode.noOffset, bool voidContext = false}) {
    // TODO(johnniwinther): Is this ever valid? Augment getters have no access
    // to the augmented setter, augmenting setters have no access to the
    // augmented getters, and augmenting fields only have read access to the
    // augmented field initializer expression.
    Expression value = _forest.createIntLiteral(offset, 1);
    if (voidContext) {
      return buildCompoundAssignment(binaryOperator, value,
          offset: offset, voidContext: voidContext, isPostIncDec: true);
    }
    VariableDeclarationImpl read =
        _helper.createVariableDeclarationForValue(_createRead());
    Expression binary = _helper.forest.createBinary(offset,
        _helper.createVariableGet(read, fileOffset), binaryOperator, value);
    VariableDeclarationImpl write = _helper.createVariableDeclarationForValue(
        _createWrite(fileOffset, binary, forEffect: true));
    return new PropertyPostIncDec.onReadOnly(read, write)..fileOffset = offset;
  }

  @override
  Expression buildSimpleRead() {
    return _createRead();
  }

  @override
  Expression_Generator_Initializer doInvocation(
      int offset, List<TypeBuilder>? typeArguments, ArgumentsImpl arguments,
      {bool isTypeArgumentsInForest = false}) {
    Member? invokeTarget = augmentation.augmentSuperTarget?.invokeTarget;
    if (invokeTarget != null) {
      return new AugmentSuperInvocation(invokeTarget, arguments,
          fileOffset: fileOffset);
    } else {
      return _helper.buildProblem(
          messageNoAugmentSuperInvokeTarget, offset, noLength);
    }
  }

  @override
  void printOn(StringSink sink) {
    sink.write(", augmentation: ");
    sink.write(augmentation);
  }
}
// Copyright (c) 2022, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

import 'dart:io';

import 'package:_fe_analyzer_shared/src/util/relativize.dart';
import 'package:dart_style/dart_style.dart' show DartFormatter;

const String dataTypeOutputPrefix = 'datatype';

const List<int> dataTypeHierarchySizes = [
  1,
  2,
  3,
  4,
  5,
  6,
  7,
  8,
  12,
  16,
  24,
  32,
  48,
  64,
  96,
  128,
  192,
  256,
  // 512, too many nested expressions or statements
  // 1024,
];

void main() {
  Uri dataFolder = Platform.script.resolve('generate


monthly_2018_05/image.thumb.png.72e2ac78aac39c7f00d2d4c91ec448c9.png_qt_ alt_eq__qt_image.thumb.png.72e2ac78aac39c7f00d2d4c91ec448c9.png_qt_ /_gt__lt_/a_gt_\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Wingnut","Date":"2018-05-08T15:37:20Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHi SL!  Got some z-fighting happening_co_ eh?  Also some bumpy-terrain protruding thru your white pads.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tyuh_co_ yuh_co_ yuh_co_ common problem... caused by your micro-processor.  Try making it stand in the corner for a half-hour.  _lt_img alt_eq__qt__dd_D_qt_ data-emoticon_eq__qt__qt_ height_eq__qt_20_qt_ src_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/default_biggrin.png_qt_ srcset_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/biggrin@2x.png 2x_qt_ title_eq__qt__dd_D_qt_ width_eq__qt_20_qt_ /_gt_ (ahem - comedy attempt)\n_lt_/p_gt_\n\n_lt_p_gt_\n\tLet_t_s see... Babylon decals... supposedly they _qt_contour_qt_ (create a unique shape)... a mesh/texture combination... which ATTEMPTS-to match the surface that it is placed-upon. \n_lt_/p_gt_\n\n_lt_p_gt_\n\tThus_co_ we should never re-position an already-created decal_co_ because the underlying bumpy-ness will be different at the new position.  Decals check the bumpy-ness of the surface... _lt_u_gt_when they are created_lt_/u_gt__co_ but cannot be updated to a new/different underlying-surface_co_ later.  (Better to make a new decal for the new location.)\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//doc.babylonjs.com/how_to/decals_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//doc.babylonjs.com/how_to/decals_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//doc.babylonjs.com/playground/?code_eq_decal_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//doc.babylonjs.com/playground/?code_eq_decal_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tHere is a playground that does some nice decal work... on a bumpy heightMap...\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_https_dd_//www.babylonjs-playground.com/#PSKRF%2310_qt_ rel_eq__qt_external nofollow