Compare commits
40 Commits
wip/jimmac
...
wip/fmuell
Author | SHA1 | Date | |
---|---|---|---|
![]() |
078a1bda14 | ||
![]() |
5edceba588 | ||
![]() |
49133c7245 | ||
![]() |
c1c00a8c1d | ||
![]() |
d3bf1a9ee7 | ||
![]() |
f43f9557e4 | ||
![]() |
a92ad59595 | ||
![]() |
616852cf2b | ||
![]() |
e5ce3d541e | ||
![]() |
925a25da17 | ||
![]() |
6743c18fdf | ||
![]() |
4d649d6ee8 | ||
![]() |
121c427438 | ||
![]() |
25fbffc454 | ||
![]() |
0e0574a0b4 | ||
![]() |
4c11d15a07 | ||
![]() |
3217c10ff2 | ||
![]() |
264050742b | ||
![]() |
cdb8ac3a2f | ||
![]() |
10b3671a99 | ||
![]() |
4d2dce2c52 | ||
![]() |
27c660d2a9 | ||
![]() |
8e7c90b930 | ||
![]() |
ff2fbf5ae4 | ||
![]() |
e77463b875 | ||
![]() |
74bb9e6249 | ||
![]() |
43041f0464 | ||
![]() |
c3ec813f6f | ||
![]() |
04d7069d83 | ||
![]() |
52c59ac0dd | ||
![]() |
240f3faf6e | ||
![]() |
284978757e | ||
![]() |
50c28714df | ||
![]() |
6099e92df5 | ||
![]() |
a4d09b4264 | ||
![]() |
6f5a099184 | ||
![]() |
8c3811a866 | ||
![]() |
118cab1766 | ||
![]() |
367b1c0627 | ||
![]() |
33b8537bf5 |
25
NEWS
@@ -1,3 +1,28 @@
|
|||||||
|
3.31.2
|
||||||
|
======
|
||||||
|
* Port away from and remove ShellGenericContainer [Georges; !153]
|
||||||
|
* popupMenu: Fix keyboard activation when numlock is active [Andrea; #550]
|
||||||
|
* Do not block all shortcuts while app folders are expanded [Florian; #648]
|
||||||
|
* Fix regression in handling new input sources [Carlos; #691]
|
||||||
|
* Reask password after udisk errors for no/wrong passwords [Sebastian; #640]
|
||||||
|
* Improve performance of app icon animations [Daniel; !253, !261]
|
||||||
|
* Avoid focus changes when updating keyboard options [Takao; #391]
|
||||||
|
* notifications: Support icon theme names in 'image-path' hint [Marco; !285]
|
||||||
|
* Respect natural-scroll setting for workspace swipe gesture [Erik; #516]
|
||||||
|
* Confine window preview titles to workspace area [Florian; !214]
|
||||||
|
* Misc. bug fixes [Florian, Carmen, Georges, Cosimo, Carlos; #602, #693,
|
||||||
|
#666, #647, !66, #768, #430, !286, !258, !287, gtk#1447]
|
||||||
|
|
||||||
|
Contributors:
|
||||||
|
Andrea Azzarone, Carmen Bianca Bakker, Cosimo Cecchi, Sergio Costas,
|
||||||
|
Erik Duxstad, Takao Fujiwara, Carlos Garnacho, Florian Müllner,
|
||||||
|
Georges Basile Stavracas Neto, Sebastian Pinnau, Didier Roche, Jakub Steiner,
|
||||||
|
Marco Trevisan (Treviño), verdre, Daniel van Vugt
|
||||||
|
|
||||||
|
Translators:
|
||||||
|
Kristjan SCHMIDT [eo], Dušan Kazik [sk], Matej Urbančič [sl],
|
||||||
|
Anish Sheela [ml], Rafael Fontenelle [pt_BR], Daniel Mustieles [es]
|
||||||
|
|
||||||
3.30.1
|
3.30.1
|
||||||
======
|
======
|
||||||
* Cancel search on overview hiding [Marco; !205]
|
* Cancel search on overview hiding [Marco; !205]
|
||||||
|
@@ -1,17 +0,0 @@
|
|||||||
The GNOME Shell Browser Plugin provides integration with gnome-shell and the
|
|
||||||
corresponding extensions repository, codenamed "SweetTooth". The plugin allows
|
|
||||||
the extensions repository to provide good integration, letting the website
|
|
||||||
know which extensions are enabled and disabled, and allowing the website to
|
|
||||||
enable, disable and install them.
|
|
||||||
|
|
||||||
Bugs should be reported to the GNOME [bug tracking system][bug-tracker].
|
|
||||||
|
|
||||||
## License
|
|
||||||
The GNOME Shell Browser Plugin, like GNOME Shell itself is distributed under
|
|
||||||
the GNU General Public License, version 2 or later. The plugin also contains
|
|
||||||
header files from the "NPAPI SDK" project, tri-licensed under MPL 1.1, GPL 2.0
|
|
||||||
and LGPL 2.1. These headers are third-party sources and can be retrieved from:
|
|
||||||
|
|
||||||
http://code.google.com/p/npapi-sdk/
|
|
||||||
|
|
||||||
[bug-tracker]: https://gitlab.gnome.org/GNOME/gnome-shell/issues
|
|
@@ -1,19 +0,0 @@
|
|||||||
plugin_sources = [
|
|
||||||
'browser-plugin.c',
|
|
||||||
'npapi/npapi.h',
|
|
||||||
'npapi/npfunctions.h',
|
|
||||||
'npapi/npruntime.h',
|
|
||||||
'npapi/nptypes.h'
|
|
||||||
]
|
|
||||||
|
|
||||||
shared_module('gnome-shell-browser-plugin', plugin_sources,
|
|
||||||
dependencies: [gio_dep, json_glib_dep],
|
|
||||||
c_args: ['-DG_LOG_DOMAIN="GnomeShellBrowserPlugin"'],
|
|
||||||
# Browsers can unload and reload the module while browsing, which is not
|
|
||||||
# supported by GObject.
|
|
||||||
# We pass -Wl,-z,nodelete to the linker to ensure the module is never
|
|
||||||
# unloaded. See https://bugzilla.gnome.org/show_bug.cgi?id=737932.
|
|
||||||
link_args: ['-Wl,-z,nodelete'],
|
|
||||||
install: true,
|
|
||||||
install_dir: plugindir
|
|
||||||
)
|
|
@@ -1,893 +0,0 @@
|
|||||||
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
||||||
/* ***** BEGIN LICENSE BLOCK *****
|
|
||||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
|
||||||
*
|
|
||||||
* The contents of this file are subject to the Mozilla Public License Version
|
|
||||||
* 1.1 (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.mozilla.org/MPL/
|
|
||||||
*
|
|
||||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
|
||||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
|
||||||
* for the specific language governing rights and limitations under the
|
|
||||||
* License.
|
|
||||||
*
|
|
||||||
* The Original Code is mozilla.org code.
|
|
||||||
*
|
|
||||||
* The Initial Developer of the Original Code is
|
|
||||||
* Netscape Communications Corporation.
|
|
||||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
|
||||||
* the Initial Developer. All Rights Reserved.
|
|
||||||
*
|
|
||||||
* Contributor(s):
|
|
||||||
*
|
|
||||||
* Alternatively, the contents of this file may be used under the terms of
|
|
||||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
|
||||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
|
||||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
|
||||||
* of those above. If you wish to allow use of your version of this file only
|
|
||||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
|
||||||
* use your version of this file under the terms of the MPL, indicate your
|
|
||||||
* decision by deleting the provisions above and replace them with the notice
|
|
||||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
|
||||||
* the provisions above, a recipient may use your version of this file under
|
|
||||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
|
||||||
*
|
|
||||||
* ***** END LICENSE BLOCK ***** */
|
|
||||||
|
|
||||||
#ifndef npapi_h_
|
|
||||||
#define npapi_h_
|
|
||||||
|
|
||||||
#if defined(__OS2__)
|
|
||||||
#pragma pack(1)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "nptypes.h"
|
|
||||||
|
|
||||||
#if defined(__OS2__) || defined(OS2)
|
|
||||||
#ifndef XP_OS2
|
|
||||||
#define XP_OS2 1
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(_WIN32) && !defined(__SYMBIAN32__)
|
|
||||||
#include <windef.h>
|
|
||||||
#ifndef XP_WIN
|
|
||||||
#define XP_WIN 1
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(__SYMBIAN32__)
|
|
||||||
#ifndef XP_SYMBIAN
|
|
||||||
#define XP_SYMBIAN 1
|
|
||||||
#undef XP_WIN
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(__APPLE_CC__) && !defined(XP_UNIX)
|
|
||||||
#ifndef XP_MACOSX
|
|
||||||
#define XP_MACOSX 1
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX) && defined(__LP64__)
|
|
||||||
#define NP_NO_QUICKDRAW
|
|
||||||
#define NP_NO_CARBON
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
#include <ApplicationServices/ApplicationServices.h>
|
|
||||||
#include <OpenGL/OpenGL.h>
|
|
||||||
#ifndef NP_NO_CARBON
|
|
||||||
#include <Carbon/Carbon.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_UNIX)
|
|
||||||
#include <stdio.h>
|
|
||||||
#if defined(MOZ_X11)
|
|
||||||
#include <X11/Xlib.h>
|
|
||||||
#include <X11/Xutil.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_SYMBIAN)
|
|
||||||
#include <QEvent>
|
|
||||||
#include <QRegion>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
/* Plugin Version Constants */
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
#define NP_VERSION_MAJOR 0
|
|
||||||
#define NP_VERSION_MINOR 27
|
|
||||||
|
|
||||||
|
|
||||||
/* The OS/2 version of Netscape uses RC_DATA to define the
|
|
||||||
mime types, file extensions, etc that are required.
|
|
||||||
Use a vertical bar to separate types, end types with \0.
|
|
||||||
FileVersion and ProductVersion are 32bit ints, all other
|
|
||||||
entries are strings that MUST be terminated with a \0.
|
|
||||||
|
|
||||||
AN EXAMPLE:
|
|
||||||
|
|
||||||
RCDATA NP_INFO_ProductVersion { 1,0,0,1,}
|
|
||||||
|
|
||||||
RCDATA NP_INFO_MIMEType { "video/x-video|",
|
|
||||||
"video/x-flick\0" }
|
|
||||||
RCDATA NP_INFO_FileExtents { "avi|",
|
|
||||||
"flc\0" }
|
|
||||||
RCDATA NP_INFO_FileOpenName{ "MMOS2 video player(*.avi)|",
|
|
||||||
"MMOS2 Flc/Fli player(*.flc)\0" }
|
|
||||||
|
|
||||||
RCDATA NP_INFO_FileVersion { 1,0,0,1 }
|
|
||||||
RCDATA NP_INFO_CompanyName { "Netscape Communications\0" }
|
|
||||||
RCDATA NP_INFO_FileDescription { "NPAVI32 Extension DLL\0"
|
|
||||||
RCDATA NP_INFO_InternalName { "NPAVI32\0" )
|
|
||||||
RCDATA NP_INFO_LegalCopyright { "Copyright Netscape Communications \251 1996\0"
|
|
||||||
RCDATA NP_INFO_OriginalFilename { "NVAPI32.DLL" }
|
|
||||||
RCDATA NP_INFO_ProductName { "NPAVI32 Dynamic Link Library\0" }
|
|
||||||
*/
|
|
||||||
/* RC_DATA types for version info - required */
|
|
||||||
#define NP_INFO_ProductVersion 1
|
|
||||||
#define NP_INFO_MIMEType 2
|
|
||||||
#define NP_INFO_FileOpenName 3
|
|
||||||
#define NP_INFO_FileExtents 4
|
|
||||||
/* RC_DATA types for version info - used if found */
|
|
||||||
#define NP_INFO_FileDescription 5
|
|
||||||
#define NP_INFO_ProductName 6
|
|
||||||
/* RC_DATA types for version info - optional */
|
|
||||||
#define NP_INFO_CompanyName 7
|
|
||||||
#define NP_INFO_FileVersion 8
|
|
||||||
#define NP_INFO_InternalName 9
|
|
||||||
#define NP_INFO_LegalCopyright 10
|
|
||||||
#define NP_INFO_OriginalFilename 11
|
|
||||||
|
|
||||||
#ifndef RC_INVOKED
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
/* Definition of Basic Types */
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
typedef unsigned char NPBool;
|
|
||||||
typedef int16_t NPError;
|
|
||||||
typedef int16_t NPReason;
|
|
||||||
typedef char* NPMIMEType;
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
/* Structures and definitions */
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
#if !defined(__LP64__)
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
#pragma options align=mac68k
|
|
||||||
#endif
|
|
||||||
#endif /* __LP64__ */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* NPP is a plug-in's opaque instance handle
|
|
||||||
*/
|
|
||||||
typedef struct _NPP
|
|
||||||
{
|
|
||||||
void* pdata; /* plug-in private data */
|
|
||||||
void* ndata; /* netscape private data */
|
|
||||||
} NPP_t;
|
|
||||||
|
|
||||||
typedef NPP_t* NPP;
|
|
||||||
|
|
||||||
typedef struct _NPStream
|
|
||||||
{
|
|
||||||
void* pdata; /* plug-in private data */
|
|
||||||
void* ndata; /* netscape private data */
|
|
||||||
const char* url;
|
|
||||||
uint32_t end;
|
|
||||||
uint32_t lastmodified;
|
|
||||||
void* notifyData;
|
|
||||||
const char* headers; /* Response headers from host.
|
|
||||||
* Exists only for >= NPVERS_HAS_RESPONSE_HEADERS.
|
|
||||||
* Used for HTTP only; NULL for non-HTTP.
|
|
||||||
* Available from NPP_NewStream onwards.
|
|
||||||
* Plugin should copy this data before storing it.
|
|
||||||
* Includes HTTP status line and all headers,
|
|
||||||
* preferably verbatim as received from server,
|
|
||||||
* headers formatted as in HTTP ("Header: Value"),
|
|
||||||
* and newlines (\n, NOT \r\n) separating lines.
|
|
||||||
* Terminated by \n\0 (NOT \n\n\0). */
|
|
||||||
} NPStream;
|
|
||||||
|
|
||||||
typedef struct _NPByteRange
|
|
||||||
{
|
|
||||||
int32_t offset; /* negative offset means from the end */
|
|
||||||
uint32_t length;
|
|
||||||
struct _NPByteRange* next;
|
|
||||||
} NPByteRange;
|
|
||||||
|
|
||||||
typedef struct _NPSavedData
|
|
||||||
{
|
|
||||||
int32_t len;
|
|
||||||
void* buf;
|
|
||||||
} NPSavedData;
|
|
||||||
|
|
||||||
typedef struct _NPRect
|
|
||||||
{
|
|
||||||
uint16_t top;
|
|
||||||
uint16_t left;
|
|
||||||
uint16_t bottom;
|
|
||||||
uint16_t right;
|
|
||||||
} NPRect;
|
|
||||||
|
|
||||||
typedef struct _NPSize
|
|
||||||
{
|
|
||||||
int32_t width;
|
|
||||||
int32_t height;
|
|
||||||
} NPSize;
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
NPFocusNext = 0,
|
|
||||||
NPFocusPrevious = 1
|
|
||||||
} NPFocusDirection;
|
|
||||||
|
|
||||||
/* Return values for NPP_HandleEvent */
|
|
||||||
#define kNPEventNotHandled 0
|
|
||||||
#define kNPEventHandled 1
|
|
||||||
/* Exact meaning must be spec'd in event model. */
|
|
||||||
#define kNPEventStartIME 2
|
|
||||||
|
|
||||||
#if defined(XP_UNIX)
|
|
||||||
/*
|
|
||||||
* Unix specific structures and definitions
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Callback Structures.
|
|
||||||
*
|
|
||||||
* These are used to pass additional platform specific information.
|
|
||||||
*/
|
|
||||||
enum {
|
|
||||||
NP_SETWINDOW = 1,
|
|
||||||
NP_PRINT
|
|
||||||
};
|
|
||||||
|
|
||||||
typedef struct
|
|
||||||
{
|
|
||||||
int32_t type;
|
|
||||||
} NPAnyCallbackStruct;
|
|
||||||
|
|
||||||
typedef struct
|
|
||||||
{
|
|
||||||
int32_t type;
|
|
||||||
#if defined(MOZ_X11)
|
|
||||||
Display* display;
|
|
||||||
Visual* visual;
|
|
||||||
Colormap colormap;
|
|
||||||
unsigned int depth;
|
|
||||||
#endif
|
|
||||||
} NPSetWindowCallbackStruct;
|
|
||||||
|
|
||||||
typedef struct
|
|
||||||
{
|
|
||||||
int32_t type;
|
|
||||||
FILE* fp;
|
|
||||||
} NPPrintCallbackStruct;
|
|
||||||
|
|
||||||
#endif /* XP_UNIX */
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
typedef enum {
|
|
||||||
#ifndef NP_NO_QUICKDRAW
|
|
||||||
NPDrawingModelQuickDraw = 0,
|
|
||||||
#endif
|
|
||||||
NPDrawingModelCoreGraphics = 1,
|
|
||||||
NPDrawingModelOpenGL = 2,
|
|
||||||
NPDrawingModelCoreAnimation = 3,
|
|
||||||
NPDrawingModelInvalidatingCoreAnimation = 4
|
|
||||||
} NPDrawingModel;
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
#ifndef NP_NO_CARBON
|
|
||||||
NPEventModelCarbon = 0,
|
|
||||||
#endif
|
|
||||||
NPEventModelCocoa = 1
|
|
||||||
} NPEventModel;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The following masks are applied on certain platforms to NPNV and
|
|
||||||
* NPPV selectors that pass around pointers to COM interfaces. Newer
|
|
||||||
* compilers on some platforms may generate vtables that are not
|
|
||||||
* compatible with older compilers. To prevent older plugins from
|
|
||||||
* not understanding a new browser's ABI, these masks change the
|
|
||||||
* values of those selectors on those platforms. To remain backwards
|
|
||||||
* compatible with different versions of the browser, plugins can
|
|
||||||
* use these masks to dynamically determine and use the correct C++
|
|
||||||
* ABI that the browser is expecting. This does not apply to Windows
|
|
||||||
* as Microsoft's COM ABI will likely not change.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#define NP_ABI_GCC3_MASK 0x10000000
|
|
||||||
/*
|
|
||||||
* gcc 3.x generated vtables on UNIX and OSX are incompatible with
|
|
||||||
* previous compilers.
|
|
||||||
*/
|
|
||||||
#if (defined(XP_UNIX) && defined(__GNUC__) && (__GNUC__ >= 3))
|
|
||||||
#define _NP_ABI_MIXIN_FOR_GCC3 NP_ABI_GCC3_MASK
|
|
||||||
#else
|
|
||||||
#define _NP_ABI_MIXIN_FOR_GCC3 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
#define NP_ABI_MACHO_MASK 0x01000000
|
|
||||||
#define _NP_ABI_MIXIN_FOR_MACHO NP_ABI_MACHO_MASK
|
|
||||||
#else
|
|
||||||
#define _NP_ABI_MIXIN_FOR_MACHO 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define NP_ABI_MASK (_NP_ABI_MIXIN_FOR_GCC3 | _NP_ABI_MIXIN_FOR_MACHO)
|
|
||||||
|
|
||||||
/*
|
|
||||||
* List of variable names for which NPP_GetValue shall be implemented
|
|
||||||
*/
|
|
||||||
typedef enum {
|
|
||||||
NPPVpluginNameString = 1,
|
|
||||||
NPPVpluginDescriptionString,
|
|
||||||
NPPVpluginWindowBool,
|
|
||||||
NPPVpluginTransparentBool,
|
|
||||||
NPPVjavaClass,
|
|
||||||
NPPVpluginWindowSize,
|
|
||||||
NPPVpluginTimerInterval,
|
|
||||||
NPPVpluginScriptableInstance = (10 | NP_ABI_MASK),
|
|
||||||
NPPVpluginScriptableIID = 11,
|
|
||||||
NPPVjavascriptPushCallerBool = 12,
|
|
||||||
NPPVpluginKeepLibraryInMemory = 13,
|
|
||||||
NPPVpluginNeedsXEmbed = 14,
|
|
||||||
|
|
||||||
/* Get the NPObject for scripting the plugin. Introduced in NPAPI minor version 14.
|
|
||||||
*/
|
|
||||||
NPPVpluginScriptableNPObject = 15,
|
|
||||||
|
|
||||||
/* Get the plugin value (as \0-terminated UTF-8 string data) for
|
|
||||||
* form submission if the plugin is part of a form. Use
|
|
||||||
* NPN_MemAlloc() to allocate memory for the string data. Introduced
|
|
||||||
* in NPAPI minor version 15.
|
|
||||||
*/
|
|
||||||
NPPVformValue = 16,
|
|
||||||
|
|
||||||
NPPVpluginUrlRequestsDisplayedBool = 17,
|
|
||||||
|
|
||||||
/* Checks if the plugin is interested in receiving the http body of
|
|
||||||
* all http requests (including failed ones, http status != 200).
|
|
||||||
*/
|
|
||||||
NPPVpluginWantsAllNetworkStreams = 18,
|
|
||||||
|
|
||||||
/* Browsers can retrieve a native ATK accessibility plug ID via this variable. */
|
|
||||||
NPPVpluginNativeAccessibleAtkPlugId = 19,
|
|
||||||
|
|
||||||
/* Checks to see if the plug-in would like the browser to load the "src" attribute. */
|
|
||||||
NPPVpluginCancelSrcStream = 20,
|
|
||||||
|
|
||||||
NPPVsupportsAdvancedKeyHandling = 21,
|
|
||||||
|
|
||||||
NPPVpluginUsesDOMForCursorBool = 22
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
/* Used for negotiating drawing models */
|
|
||||||
, NPPVpluginDrawingModel = 1000
|
|
||||||
/* Used for negotiating event models */
|
|
||||||
, NPPVpluginEventModel = 1001
|
|
||||||
/* In the NPDrawingModelCoreAnimation drawing model, the browser asks the plug-in for a Core Animation layer. */
|
|
||||||
, NPPVpluginCoreAnimationLayer = 1003
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (MOZ_PLATFORM_MAEMO == 5) || (MOZ_PLATFORM_MAEMO == 6)
|
|
||||||
, NPPVpluginWindowlessLocalBool = 2002
|
|
||||||
#endif
|
|
||||||
} NPPVariable;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* List of variable names for which NPN_GetValue should be implemented.
|
|
||||||
*/
|
|
||||||
typedef enum {
|
|
||||||
NPNVxDisplay = 1,
|
|
||||||
NPNVxtAppContext,
|
|
||||||
NPNVnetscapeWindow,
|
|
||||||
NPNVjavascriptEnabledBool,
|
|
||||||
NPNVasdEnabledBool,
|
|
||||||
NPNVisOfflineBool,
|
|
||||||
|
|
||||||
NPNVserviceManager = (10 | NP_ABI_MASK),
|
|
||||||
NPNVDOMElement = (11 | NP_ABI_MASK),
|
|
||||||
NPNVDOMWindow = (12 | NP_ABI_MASK),
|
|
||||||
NPNVToolkit = (13 | NP_ABI_MASK),
|
|
||||||
NPNVSupportsXEmbedBool = 14,
|
|
||||||
|
|
||||||
/* Get the NPObject wrapper for the browser window. */
|
|
||||||
NPNVWindowNPObject = 15,
|
|
||||||
|
|
||||||
/* Get the NPObject wrapper for the plugins DOM element. */
|
|
||||||
NPNVPluginElementNPObject = 16,
|
|
||||||
|
|
||||||
NPNVSupportsWindowless = 17,
|
|
||||||
|
|
||||||
NPNVprivateModeBool = 18,
|
|
||||||
|
|
||||||
NPNVsupportsAdvancedKeyHandling = 21
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
/* Used for negotiating drawing models */
|
|
||||||
, NPNVpluginDrawingModel = 1000
|
|
||||||
#ifndef NP_NO_QUICKDRAW
|
|
||||||
, NPNVsupportsQuickDrawBool = 2000
|
|
||||||
#endif
|
|
||||||
, NPNVsupportsCoreGraphicsBool = 2001
|
|
||||||
, NPNVsupportsOpenGLBool = 2002
|
|
||||||
, NPNVsupportsCoreAnimationBool = 2003
|
|
||||||
, NPNVsupportsInvalidatingCoreAnimationBool = 2004
|
|
||||||
#ifndef NP_NO_CARBON
|
|
||||||
, NPNVsupportsCarbonBool = 3000 /* TRUE if the browser supports the Carbon event model */
|
|
||||||
#endif
|
|
||||||
, NPNVsupportsCocoaBool = 3001 /* TRUE if the browser supports the Cocoa event model */
|
|
||||||
, NPNVsupportsUpdatedCocoaTextInputBool = 3002 /* TRUE if the browser supports the updated
|
|
||||||
Cocoa text input specification. */
|
|
||||||
, NPNVsupportsCompositingCoreAnimationPluginsBool = 74656 /* TRUE if the browser supports
|
|
||||||
CA model compositing */
|
|
||||||
#endif
|
|
||||||
#if (MOZ_PLATFORM_MAEMO == 5) || (MOZ_PLATFORM_MAEMO == 6)
|
|
||||||
, NPNVSupportsWindowlessLocal = 2002
|
|
||||||
#endif
|
|
||||||
} NPNVariable;
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
NPNURLVCookie = 501,
|
|
||||||
NPNURLVProxy
|
|
||||||
} NPNURLVariable;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The type of Toolkit the widgets use
|
|
||||||
*/
|
|
||||||
typedef enum {
|
|
||||||
NPNVGtk12 = 1,
|
|
||||||
NPNVGtk2
|
|
||||||
} NPNToolkitType;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The type of a NPWindow - it specifies the type of the data structure
|
|
||||||
* returned in the window field.
|
|
||||||
*/
|
|
||||||
typedef enum {
|
|
||||||
NPWindowTypeWindow = 1,
|
|
||||||
NPWindowTypeDrawable
|
|
||||||
} NPWindowType;
|
|
||||||
|
|
||||||
typedef struct _NPWindow
|
|
||||||
{
|
|
||||||
void* window; /* Platform specific window handle */
|
|
||||||
/* OS/2: x - Position of bottom left corner */
|
|
||||||
/* OS/2: y - relative to visible netscape window */
|
|
||||||
int32_t x; /* Position of top left corner relative */
|
|
||||||
int32_t y; /* to a netscape page. */
|
|
||||||
uint32_t width; /* Maximum window size */
|
|
||||||
uint32_t height;
|
|
||||||
NPRect clipRect; /* Clipping rectangle in port coordinates */
|
|
||||||
#if (defined(XP_UNIX) || defined(XP_SYMBIAN)) && !defined(XP_MACOSX)
|
|
||||||
void * ws_info; /* Platform-dependent additional data */
|
|
||||||
#endif /* XP_UNIX */
|
|
||||||
NPWindowType type; /* Is this a window or a drawable? */
|
|
||||||
} NPWindow;
|
|
||||||
|
|
||||||
typedef struct _NPImageExpose
|
|
||||||
{
|
|
||||||
char* data; /* image pointer */
|
|
||||||
int32_t stride; /* Stride of data image pointer */
|
|
||||||
int32_t depth; /* Depth of image pointer */
|
|
||||||
int32_t x; /* Expose x */
|
|
||||||
int32_t y; /* Expose y */
|
|
||||||
uint32_t width; /* Expose width */
|
|
||||||
uint32_t height; /* Expose height */
|
|
||||||
NPSize dataSize; /* Data buffer size */
|
|
||||||
float translateX; /* translate X matrix value */
|
|
||||||
float translateY; /* translate Y matrix value */
|
|
||||||
float scaleX; /* scale X matrix value */
|
|
||||||
float scaleY; /* scale Y matrix value */
|
|
||||||
} NPImageExpose;
|
|
||||||
|
|
||||||
typedef struct _NPFullPrint
|
|
||||||
{
|
|
||||||
NPBool pluginPrinted;/* Set TRUE if plugin handled fullscreen printing */
|
|
||||||
NPBool printOne; /* TRUE if plugin should print one copy to default
|
|
||||||
printer */
|
|
||||||
void* platformPrint; /* Platform-specific printing info */
|
|
||||||
} NPFullPrint;
|
|
||||||
|
|
||||||
typedef struct _NPEmbedPrint
|
|
||||||
{
|
|
||||||
NPWindow window;
|
|
||||||
void* platformPrint; /* Platform-specific printing info */
|
|
||||||
} NPEmbedPrint;
|
|
||||||
|
|
||||||
typedef struct _NPPrint
|
|
||||||
{
|
|
||||||
uint16_t mode; /* NP_FULL or NP_EMBED */
|
|
||||||
union
|
|
||||||
{
|
|
||||||
NPFullPrint fullPrint; /* if mode is NP_FULL */
|
|
||||||
NPEmbedPrint embedPrint; /* if mode is NP_EMBED */
|
|
||||||
} print;
|
|
||||||
} NPPrint;
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
#ifndef NP_NO_CARBON
|
|
||||||
typedef EventRecord NPEvent;
|
|
||||||
#endif
|
|
||||||
#elif defined(XP_SYMBIAN)
|
|
||||||
typedef QEvent NPEvent;
|
|
||||||
#elif defined(XP_WIN)
|
|
||||||
typedef struct _NPEvent
|
|
||||||
{
|
|
||||||
uint16_t event;
|
|
||||||
uintptr_t wParam;
|
|
||||||
uintptr_t lParam;
|
|
||||||
} NPEvent;
|
|
||||||
#elif defined(XP_OS2)
|
|
||||||
typedef struct _NPEvent
|
|
||||||
{
|
|
||||||
uint32_t event;
|
|
||||||
uint32_t wParam;
|
|
||||||
uint32_t lParam;
|
|
||||||
} NPEvent;
|
|
||||||
#elif defined(XP_UNIX) && defined(MOZ_X11)
|
|
||||||
typedef XEvent NPEvent;
|
|
||||||
#else
|
|
||||||
typedef void* NPEvent;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
typedef void* NPRegion;
|
|
||||||
#ifndef NP_NO_QUICKDRAW
|
|
||||||
typedef RgnHandle NPQDRegion;
|
|
||||||
#endif
|
|
||||||
typedef CGPathRef NPCGRegion;
|
|
||||||
#elif defined(XP_WIN)
|
|
||||||
typedef HRGN NPRegion;
|
|
||||||
#elif defined(XP_UNIX) && defined(MOZ_X11)
|
|
||||||
typedef Region NPRegion;
|
|
||||||
#elif defined(XP_SYMBIAN)
|
|
||||||
typedef QRegion* NPRegion;
|
|
||||||
#else
|
|
||||||
typedef void *NPRegion;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef struct _NPNSString NPNSString;
|
|
||||||
typedef struct _NPNSWindow NPNSWindow;
|
|
||||||
typedef struct _NPNSMenu NPNSMenu;
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
typedef NPNSMenu NPMenu;
|
|
||||||
#else
|
|
||||||
typedef void *NPMenu;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
NPCoordinateSpacePlugin = 1,
|
|
||||||
NPCoordinateSpaceWindow,
|
|
||||||
NPCoordinateSpaceFlippedWindow,
|
|
||||||
NPCoordinateSpaceScreen,
|
|
||||||
NPCoordinateSpaceFlippedScreen
|
|
||||||
} NPCoordinateSpace;
|
|
||||||
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
|
|
||||||
#ifndef NP_NO_QUICKDRAW
|
|
||||||
typedef struct NP_Port
|
|
||||||
{
|
|
||||||
CGrafPtr port;
|
|
||||||
int32_t portx; /* position inside the topmost window */
|
|
||||||
int32_t porty;
|
|
||||||
} NP_Port;
|
|
||||||
#endif /* NP_NO_QUICKDRAW */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* NP_CGContext is the type of the NPWindow's 'window' when the plugin specifies NPDrawingModelCoreGraphics
|
|
||||||
* as its drawing model.
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef struct NP_CGContext
|
|
||||||
{
|
|
||||||
CGContextRef context;
|
|
||||||
void *window; /* A WindowRef under the Carbon event model. */
|
|
||||||
} NP_CGContext;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* NP_GLContext is the type of the NPWindow's 'window' when the plugin specifies NPDrawingModelOpenGL as its
|
|
||||||
* drawing model.
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef struct NP_GLContext
|
|
||||||
{
|
|
||||||
CGLContextObj context;
|
|
||||||
#ifdef NP_NO_CARBON
|
|
||||||
NPNSWindow *window;
|
|
||||||
#else
|
|
||||||
void *window; /* Can be either an NSWindow or a WindowRef depending on the event model */
|
|
||||||
#endif
|
|
||||||
} NP_GLContext;
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
NPCocoaEventDrawRect = 1,
|
|
||||||
NPCocoaEventMouseDown,
|
|
||||||
NPCocoaEventMouseUp,
|
|
||||||
NPCocoaEventMouseMoved,
|
|
||||||
NPCocoaEventMouseEntered,
|
|
||||||
NPCocoaEventMouseExited,
|
|
||||||
NPCocoaEventMouseDragged,
|
|
||||||
NPCocoaEventKeyDown,
|
|
||||||
NPCocoaEventKeyUp,
|
|
||||||
NPCocoaEventFlagsChanged,
|
|
||||||
NPCocoaEventFocusChanged,
|
|
||||||
NPCocoaEventWindowFocusChanged,
|
|
||||||
NPCocoaEventScrollWheel,
|
|
||||||
NPCocoaEventTextInput
|
|
||||||
} NPCocoaEventType;
|
|
||||||
|
|
||||||
typedef struct _NPCocoaEvent {
|
|
||||||
NPCocoaEventType type;
|
|
||||||
uint32_t version;
|
|
||||||
union {
|
|
||||||
struct {
|
|
||||||
uint32_t modifierFlags;
|
|
||||||
double pluginX;
|
|
||||||
double pluginY;
|
|
||||||
int32_t buttonNumber;
|
|
||||||
int32_t clickCount;
|
|
||||||
double deltaX;
|
|
||||||
double deltaY;
|
|
||||||
double deltaZ;
|
|
||||||
} mouse;
|
|
||||||
struct {
|
|
||||||
uint32_t modifierFlags;
|
|
||||||
NPNSString *characters;
|
|
||||||
NPNSString *charactersIgnoringModifiers;
|
|
||||||
NPBool isARepeat;
|
|
||||||
uint16_t keyCode;
|
|
||||||
} key;
|
|
||||||
struct {
|
|
||||||
CGContextRef context;
|
|
||||||
double x;
|
|
||||||
double y;
|
|
||||||
double width;
|
|
||||||
double height;
|
|
||||||
} draw;
|
|
||||||
struct {
|
|
||||||
NPBool hasFocus;
|
|
||||||
} focus;
|
|
||||||
struct {
|
|
||||||
NPNSString *text;
|
|
||||||
} text;
|
|
||||||
} data;
|
|
||||||
} NPCocoaEvent;
|
|
||||||
|
|
||||||
#ifndef NP_NO_CARBON
|
|
||||||
/* Non-standard event types that can be passed to HandleEvent */
|
|
||||||
enum NPEventType {
|
|
||||||
NPEventType_GetFocusEvent = (osEvt + 16),
|
|
||||||
NPEventType_LoseFocusEvent,
|
|
||||||
NPEventType_AdjustCursorEvent,
|
|
||||||
NPEventType_MenuCommandEvent,
|
|
||||||
NPEventType_ClippingChangedEvent,
|
|
||||||
NPEventType_ScrollingBeginsEvent = 1000,
|
|
||||||
NPEventType_ScrollingEndsEvent
|
|
||||||
};
|
|
||||||
#endif /* NP_NO_CARBON */
|
|
||||||
|
|
||||||
#endif /* XP_MACOSX */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Values for mode passed to NPP_New:
|
|
||||||
*/
|
|
||||||
#define NP_EMBED 1
|
|
||||||
#define NP_FULL 2
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Values for stream type passed to NPP_NewStream:
|
|
||||||
*/
|
|
||||||
#define NP_NORMAL 1
|
|
||||||
#define NP_SEEK 2
|
|
||||||
#define NP_ASFILE 3
|
|
||||||
#define NP_ASFILEONLY 4
|
|
||||||
|
|
||||||
#define NP_MAXREADY (((unsigned)(~0)<<1)>>1)
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Flags for NPP_ClearSiteData.
|
|
||||||
*/
|
|
||||||
#define NP_CLEAR_ALL 0
|
|
||||||
#define NP_CLEAR_CACHE (1 << 0)
|
|
||||||
|
|
||||||
#if !defined(__LP64__)
|
|
||||||
#if defined(XP_MACOSX)
|
|
||||||
#pragma options align=reset
|
|
||||||
#endif
|
|
||||||
#endif /* __LP64__ */
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
/* Error and Reason Code definitions */
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Values of type NPError:
|
|
||||||
*/
|
|
||||||
#define NPERR_BASE 0
|
|
||||||
#define NPERR_NO_ERROR (NPERR_BASE + 0)
|
|
||||||
#define NPERR_GENERIC_ERROR (NPERR_BASE + 1)
|
|
||||||
#define NPERR_INVALID_INSTANCE_ERROR (NPERR_BASE + 2)
|
|
||||||
#define NPERR_INVALID_FUNCTABLE_ERROR (NPERR_BASE + 3)
|
|
||||||
#define NPERR_MODULE_LOAD_FAILED_ERROR (NPERR_BASE + 4)
|
|
||||||
#define NPERR_OUT_OF_MEMORY_ERROR (NPERR_BASE + 5)
|
|
||||||
#define NPERR_INVALID_PLUGIN_ERROR (NPERR_BASE + 6)
|
|
||||||
#define NPERR_INVALID_PLUGIN_DIR_ERROR (NPERR_BASE + 7)
|
|
||||||
#define NPERR_INCOMPATIBLE_VERSION_ERROR (NPERR_BASE + 8)
|
|
||||||
#define NPERR_INVALID_PARAM (NPERR_BASE + 9)
|
|
||||||
#define NPERR_INVALID_URL (NPERR_BASE + 10)
|
|
||||||
#define NPERR_FILE_NOT_FOUND (NPERR_BASE + 11)
|
|
||||||
#define NPERR_NO_DATA (NPERR_BASE + 12)
|
|
||||||
#define NPERR_STREAM_NOT_SEEKABLE (NPERR_BASE + 13)
|
|
||||||
#define NPERR_TIME_RANGE_NOT_SUPPORTED (NPERR_BASE + 14)
|
|
||||||
#define NPERR_MALFORMED_SITE (NPERR_BASE + 15)
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Values of type NPReason:
|
|
||||||
*/
|
|
||||||
#define NPRES_BASE 0
|
|
||||||
#define NPRES_DONE (NPRES_BASE + 0)
|
|
||||||
#define NPRES_NETWORK_ERR (NPRES_BASE + 1)
|
|
||||||
#define NPRES_USER_BREAK (NPRES_BASE + 2)
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Don't use these obsolete error codes any more.
|
|
||||||
*/
|
|
||||||
#define NP_NOERR NP_NOERR_is_obsolete_use_NPERR_NO_ERROR
|
|
||||||
#define NP_EINVAL NP_EINVAL_is_obsolete_use_NPERR_GENERIC_ERROR
|
|
||||||
#define NP_EABORT NP_EABORT_is_obsolete_use_NPRES_USER_BREAK
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Version feature information
|
|
||||||
*/
|
|
||||||
#define NPVERS_HAS_STREAMOUTPUT 8
|
|
||||||
#define NPVERS_HAS_NOTIFICATION 9
|
|
||||||
#define NPVERS_HAS_LIVECONNECT 9
|
|
||||||
#define NPVERS_68K_HAS_LIVECONNECT 11
|
|
||||||
#define NPVERS_HAS_WINDOWLESS 11
|
|
||||||
#define NPVERS_HAS_XPCONNECT_SCRIPTING 13
|
|
||||||
#define NPVERS_HAS_NPRUNTIME_SCRIPTING 14
|
|
||||||
#define NPVERS_HAS_FORM_VALUES 15
|
|
||||||
#define NPVERS_HAS_POPUPS_ENABLED_STATE 16
|
|
||||||
#define NPVERS_HAS_RESPONSE_HEADERS 17
|
|
||||||
#define NPVERS_HAS_NPOBJECT_ENUM 18
|
|
||||||
#define NPVERS_HAS_PLUGIN_THREAD_ASYNC_CALL 19
|
|
||||||
#define NPVERS_HAS_ALL_NETWORK_STREAMS 20
|
|
||||||
#define NPVERS_HAS_URL_AND_AUTH_INFO 21
|
|
||||||
#define NPVERS_HAS_PRIVATE_MODE 22
|
|
||||||
#define NPVERS_MACOSX_HAS_COCOA_EVENTS 23
|
|
||||||
#define NPVERS_HAS_ADVANCED_KEY_HANDLING 25
|
|
||||||
#define NPVERS_HAS_URL_REDIRECT_HANDLING 26
|
|
||||||
#define NPVERS_HAS_CLEAR_SITE_DATA 27
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
/* Function Prototypes */
|
|
||||||
/*----------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
#if defined(__OS2__)
|
|
||||||
#define NP_LOADDS _System
|
|
||||||
#else
|
|
||||||
#define NP_LOADDS
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C" {
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* NPP_* functions are provided by the plugin and called by the navigator. */
|
|
||||||
|
|
||||||
#if defined(XP_UNIX)
|
|
||||||
const char* NPP_GetMIMEDescription(void);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
NPError NP_LOADDS NPP_New(NPMIMEType pluginType, NPP instance,
|
|
||||||
uint16_t mode, int16_t argc, char* argn[],
|
|
||||||
char* argv[], NPSavedData* saved);
|
|
||||||
NPError NP_LOADDS NPP_Destroy(NPP instance, NPSavedData** save);
|
|
||||||
NPError NP_LOADDS NPP_SetWindow(NPP instance, NPWindow* window);
|
|
||||||
NPError NP_LOADDS NPP_NewStream(NPP instance, NPMIMEType type,
|
|
||||||
NPStream* stream, NPBool seekable,
|
|
||||||
uint16_t* stype);
|
|
||||||
NPError NP_LOADDS NPP_DestroyStream(NPP instance, NPStream* stream,
|
|
||||||
NPReason reason);
|
|
||||||
int32_t NP_LOADDS NPP_WriteReady(NPP instance, NPStream* stream);
|
|
||||||
int32_t NP_LOADDS NPP_Write(NPP instance, NPStream* stream, int32_t offset,
|
|
||||||
int32_t len, void* buffer);
|
|
||||||
void NP_LOADDS NPP_StreamAsFile(NPP instance, NPStream* stream,
|
|
||||||
const char* fname);
|
|
||||||
void NP_LOADDS NPP_Print(NPP instance, NPPrint* platformPrint);
|
|
||||||
int16_t NP_LOADDS NPP_HandleEvent(NPP instance, void* event);
|
|
||||||
void NP_LOADDS NPP_URLNotify(NPP instance, const char* url,
|
|
||||||
NPReason reason, void* notifyData);
|
|
||||||
NPError NP_LOADDS NPP_GetValue(NPP instance, NPPVariable variable, void *value);
|
|
||||||
NPError NP_LOADDS NPP_SetValue(NPP instance, NPNVariable variable, void *value);
|
|
||||||
NPBool NP_LOADDS NPP_GotFocus(NPP instance, NPFocusDirection direction);
|
|
||||||
void NP_LOADDS NPP_LostFocus(NPP instance);
|
|
||||||
void NP_LOADDS NPP_URLRedirectNotify(NPP instance, const char* url, int32_t status, void* notifyData);
|
|
||||||
NPError NP_LOADDS NPP_ClearSiteData(const char* site, uint64_t flags, uint64_t maxAge);
|
|
||||||
char** NP_LOADDS NPP_GetSitesWithData(void);
|
|
||||||
|
|
||||||
/* NPN_* functions are provided by the navigator and called by the plugin. */
|
|
||||||
void NP_LOADDS NPN_Version(int* plugin_major, int* plugin_minor,
|
|
||||||
int* netscape_major, int* netscape_minor);
|
|
||||||
NPError NP_LOADDS NPN_GetURLNotify(NPP instance, const char* url,
|
|
||||||
const char* target, void* notifyData);
|
|
||||||
NPError NP_LOADDS NPN_GetURL(NPP instance, const char* url,
|
|
||||||
const char* target);
|
|
||||||
NPError NP_LOADDS NPN_PostURLNotify(NPP instance, const char* url,
|
|
||||||
const char* target, uint32_t len,
|
|
||||||
const char* buf, NPBool file,
|
|
||||||
void* notifyData);
|
|
||||||
NPError NP_LOADDS NPN_PostURL(NPP instance, const char* url,
|
|
||||||
const char* target, uint32_t len,
|
|
||||||
const char* buf, NPBool file);
|
|
||||||
NPError NP_LOADDS NPN_RequestRead(NPStream* stream, NPByteRange* rangeList);
|
|
||||||
NPError NP_LOADDS NPN_NewStream(NPP instance, NPMIMEType type,
|
|
||||||
const char* target, NPStream** stream);
|
|
||||||
int32_t NP_LOADDS NPN_Write(NPP instance, NPStream* stream, int32_t len,
|
|
||||||
void* buffer);
|
|
||||||
NPError NP_LOADDS NPN_DestroyStream(NPP instance, NPStream* stream,
|
|
||||||
NPReason reason);
|
|
||||||
void NP_LOADDS NPN_Status(NPP instance, const char* message);
|
|
||||||
const char* NP_LOADDS NPN_UserAgent(NPP instance);
|
|
||||||
void* NP_LOADDS NPN_MemAlloc(uint32_t size);
|
|
||||||
void NP_LOADDS NPN_MemFree(void* ptr);
|
|
||||||
uint32_t NP_LOADDS NPN_MemFlush(uint32_t size);
|
|
||||||
void NP_LOADDS NPN_ReloadPlugins(NPBool reloadPages);
|
|
||||||
NPError NP_LOADDS NPN_GetValue(NPP instance, NPNVariable variable,
|
|
||||||
void *value);
|
|
||||||
NPError NP_LOADDS NPN_SetValue(NPP instance, NPPVariable variable,
|
|
||||||
void *value);
|
|
||||||
void NP_LOADDS NPN_InvalidateRect(NPP instance, NPRect *invalidRect);
|
|
||||||
void NP_LOADDS NPN_InvalidateRegion(NPP instance,
|
|
||||||
NPRegion invalidRegion);
|
|
||||||
void NP_LOADDS NPN_ForceRedraw(NPP instance);
|
|
||||||
void NP_LOADDS NPN_PushPopupsEnabledState(NPP instance, NPBool enabled);
|
|
||||||
void NP_LOADDS NPN_PopPopupsEnabledState(NPP instance);
|
|
||||||
void NP_LOADDS NPN_PluginThreadAsyncCall(NPP instance,
|
|
||||||
void (*func) (void *),
|
|
||||||
void *userData);
|
|
||||||
NPError NP_LOADDS NPN_GetValueForURL(NPP instance, NPNURLVariable variable,
|
|
||||||
const char *url, char **value,
|
|
||||||
uint32_t *len);
|
|
||||||
NPError NP_LOADDS NPN_SetValueForURL(NPP instance, NPNURLVariable variable,
|
|
||||||
const char *url, const char *value,
|
|
||||||
uint32_t len);
|
|
||||||
NPError NP_LOADDS NPN_GetAuthenticationInfo(NPP instance,
|
|
||||||
const char *protocol,
|
|
||||||
const char *host, int32_t port,
|
|
||||||
const char *scheme,
|
|
||||||
const char *realm,
|
|
||||||
char **username, uint32_t *ulen,
|
|
||||||
char **password,
|
|
||||||
uint32_t *plen);
|
|
||||||
uint32_t NP_LOADDS NPN_ScheduleTimer(NPP instance, uint32_t interval, NPBool repeat, void (*timerFunc)(NPP npp, uint32_t timerID));
|
|
||||||
void NP_LOADDS NPN_UnscheduleTimer(NPP instance, uint32_t timerID);
|
|
||||||
NPError NP_LOADDS NPN_PopUpContextMenu(NPP instance, NPMenu* menu);
|
|
||||||
NPBool NP_LOADDS NPN_ConvertPoint(NPP instance, double sourceX, double sourceY, NPCoordinateSpace sourceSpace, double *destX, double *destY, NPCoordinateSpace destSpace);
|
|
||||||
NPBool NP_LOADDS NPN_HandleEvent(NPP instance, void *event, NPBool handled);
|
|
||||||
NPBool NP_LOADDS NPN_UnfocusInstance(NPP instance, NPFocusDirection direction);
|
|
||||||
void NP_LOADDS NPN_URLRedirectResponse(NPP instance, void* notifyData, NPBool allow);
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
|
||||||
} /* end extern "C" */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* RC_INVOKED */
|
|
||||||
#if defined(__OS2__)
|
|
||||||
#pragma pack()
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* npapi_h_ */
|
|
@@ -1,322 +0,0 @@
|
|||||||
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
||||||
/* ***** BEGIN LICENSE BLOCK *****
|
|
||||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
|
||||||
*
|
|
||||||
* The contents of this file are subject to the Mozilla Public License Version
|
|
||||||
* 1.1 (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.mozilla.org/MPL/
|
|
||||||
*
|
|
||||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
|
||||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
|
||||||
* for the specific language governing rights and limitations under the
|
|
||||||
* License.
|
|
||||||
*
|
|
||||||
* The Original Code is mozilla.org code.
|
|
||||||
*
|
|
||||||
* The Initial Developer of the Original Code is
|
|
||||||
* Netscape Communications Corporation.
|
|
||||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
|
||||||
* the Initial Developer. All Rights Reserved.
|
|
||||||
*
|
|
||||||
* Contributor(s):
|
|
||||||
*
|
|
||||||
* Alternatively, the contents of this file may be used under the terms of
|
|
||||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
|
||||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
|
||||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
|
||||||
* of those above. If you wish to allow use of your version of this file only
|
|
||||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
|
||||||
* use your version of this file under the terms of the MPL, indicate your
|
|
||||||
* decision by deleting the provisions above and replace them with the notice
|
|
||||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
|
||||||
* the provisions above, a recipient may use your version of this file under
|
|
||||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
|
||||||
*
|
|
||||||
* ***** END LICENSE BLOCK ***** */
|
|
||||||
|
|
||||||
#ifndef npfunctions_h_
|
|
||||||
#define npfunctions_h_
|
|
||||||
|
|
||||||
#ifdef __OS2__
|
|
||||||
#pragma pack(1)
|
|
||||||
#define NP_LOADDS _System
|
|
||||||
#else
|
|
||||||
#define NP_LOADDS
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "npapi.h"
|
|
||||||
#include "npruntime.h"
|
|
||||||
|
|
||||||
typedef NPError (* NP_LOADDS NPP_NewProcPtr)(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char* argn[], char* argv[], NPSavedData* saved);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_DestroyProcPtr)(NPP instance, NPSavedData** save);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_SetWindowProcPtr)(NPP instance, NPWindow* window);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_NewStreamProcPtr)(NPP instance, NPMIMEType type, NPStream* stream, NPBool seekable, uint16_t* stype);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_DestroyStreamProcPtr)(NPP instance, NPStream* stream, NPReason reason);
|
|
||||||
typedef int32_t (* NP_LOADDS NPP_WriteReadyProcPtr)(NPP instance, NPStream* stream);
|
|
||||||
typedef int32_t (* NP_LOADDS NPP_WriteProcPtr)(NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer);
|
|
||||||
typedef void (* NP_LOADDS NPP_StreamAsFileProcPtr)(NPP instance, NPStream* stream, const char* fname);
|
|
||||||
typedef void (* NP_LOADDS NPP_PrintProcPtr)(NPP instance, NPPrint* platformPrint);
|
|
||||||
typedef int16_t (* NP_LOADDS NPP_HandleEventProcPtr)(NPP instance, void* event);
|
|
||||||
typedef void (* NP_LOADDS NPP_URLNotifyProcPtr)(NPP instance, const char* url, NPReason reason, void* notifyData);
|
|
||||||
/* Any NPObjects returned to the browser via NPP_GetValue should be retained
|
|
||||||
by the plugin on the way out. The browser is responsible for releasing. */
|
|
||||||
typedef NPError (* NP_LOADDS NPP_GetValueProcPtr)(NPP instance, NPPVariable variable, void *ret_value);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_SetValueProcPtr)(NPP instance, NPNVariable variable, void *value);
|
|
||||||
typedef NPBool (* NP_LOADDS NPP_GotFocusPtr)(NPP instance, NPFocusDirection direction);
|
|
||||||
typedef void (* NP_LOADDS NPP_LostFocusPtr)(NPP instance);
|
|
||||||
typedef void (* NP_LOADDS NPP_URLRedirectNotifyPtr)(NPP instance, const char* url, int32_t status, void* notifyData);
|
|
||||||
typedef NPError (* NP_LOADDS NPP_ClearSiteDataPtr)(const char* site, uint64_t flags, uint64_t maxAge);
|
|
||||||
typedef char** (* NP_LOADDS NPP_GetSitesWithDataPtr)(void);
|
|
||||||
|
|
||||||
typedef NPError (*NPN_GetValueProcPtr)(NPP instance, NPNVariable variable, void *ret_value);
|
|
||||||
typedef NPError (*NPN_SetValueProcPtr)(NPP instance, NPPVariable variable, void *value);
|
|
||||||
typedef NPError (*NPN_GetURLNotifyProcPtr)(NPP instance, const char* url, const char* window, void* notifyData);
|
|
||||||
typedef NPError (*NPN_PostURLNotifyProcPtr)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file, void* notifyData);
|
|
||||||
typedef NPError (*NPN_GetURLProcPtr)(NPP instance, const char* url, const char* window);
|
|
||||||
typedef NPError (*NPN_PostURLProcPtr)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file);
|
|
||||||
typedef NPError (*NPN_RequestReadProcPtr)(NPStream* stream, NPByteRange* rangeList);
|
|
||||||
typedef NPError (*NPN_NewStreamProcPtr)(NPP instance, NPMIMEType type, const char* window, NPStream** stream);
|
|
||||||
typedef int32_t (*NPN_WriteProcPtr)(NPP instance, NPStream* stream, int32_t len, void* buffer);
|
|
||||||
typedef NPError (*NPN_DestroyStreamProcPtr)(NPP instance, NPStream* stream, NPReason reason);
|
|
||||||
typedef void (*NPN_StatusProcPtr)(NPP instance, const char* message);
|
|
||||||
/* Browser manages the lifetime of the buffer returned by NPN_UserAgent, don't
|
|
||||||
depend on it sticking around and don't free it. */
|
|
||||||
typedef const char* (*NPN_UserAgentProcPtr)(NPP instance);
|
|
||||||
typedef void* (*NPN_MemAllocProcPtr)(uint32_t size);
|
|
||||||
typedef void (*NPN_MemFreeProcPtr)(void* ptr);
|
|
||||||
typedef uint32_t (*NPN_MemFlushProcPtr)(uint32_t size);
|
|
||||||
typedef void (*NPN_ReloadPluginsProcPtr)(NPBool reloadPages);
|
|
||||||
typedef void* (*NPN_GetJavaEnvProcPtr)(void);
|
|
||||||
typedef void* (*NPN_GetJavaPeerProcPtr)(NPP instance);
|
|
||||||
typedef void (*NPN_InvalidateRectProcPtr)(NPP instance, NPRect *rect);
|
|
||||||
typedef void (*NPN_InvalidateRegionProcPtr)(NPP instance, NPRegion region);
|
|
||||||
typedef void (*NPN_ForceRedrawProcPtr)(NPP instance);
|
|
||||||
typedef NPIdentifier (*NPN_GetStringIdentifierProcPtr)(const NPUTF8* name);
|
|
||||||
typedef void (*NPN_GetStringIdentifiersProcPtr)(const NPUTF8** names, int32_t nameCount, NPIdentifier* identifiers);
|
|
||||||
typedef NPIdentifier (*NPN_GetIntIdentifierProcPtr)(int32_t intid);
|
|
||||||
typedef bool (*NPN_IdentifierIsStringProcPtr)(NPIdentifier identifier);
|
|
||||||
typedef NPUTF8* (*NPN_UTF8FromIdentifierProcPtr)(NPIdentifier identifier);
|
|
||||||
typedef int32_t (*NPN_IntFromIdentifierProcPtr)(NPIdentifier identifier);
|
|
||||||
typedef NPObject* (*NPN_CreateObjectProcPtr)(NPP npp, NPClass *aClass);
|
|
||||||
typedef NPObject* (*NPN_RetainObjectProcPtr)(NPObject *obj);
|
|
||||||
typedef void (*NPN_ReleaseObjectProcPtr)(NPObject *obj);
|
|
||||||
typedef bool (*NPN_InvokeProcPtr)(NPP npp, NPObject* obj, NPIdentifier methodName, const NPVariant *args, uint32_t argCount, NPVariant *result);
|
|
||||||
typedef bool (*NPN_InvokeDefaultProcPtr)(NPP npp, NPObject* obj, const NPVariant *args, uint32_t argCount, NPVariant *result);
|
|
||||||
typedef bool (*NPN_EvaluateProcPtr)(NPP npp, NPObject *obj, NPString *script, NPVariant *result);
|
|
||||||
typedef bool (*NPN_GetPropertyProcPtr)(NPP npp, NPObject *obj, NPIdentifier propertyName, NPVariant *result);
|
|
||||||
typedef bool (*NPN_SetPropertyProcPtr)(NPP npp, NPObject *obj, NPIdentifier propertyName, const NPVariant *value);
|
|
||||||
typedef bool (*NPN_RemovePropertyProcPtr)(NPP npp, NPObject *obj, NPIdentifier propertyName);
|
|
||||||
typedef bool (*NPN_HasPropertyProcPtr)(NPP npp, NPObject *obj, NPIdentifier propertyName);
|
|
||||||
typedef bool (*NPN_HasMethodProcPtr)(NPP npp, NPObject *obj, NPIdentifier propertyName);
|
|
||||||
typedef void (*NPN_ReleaseVariantValueProcPtr)(NPVariant *variant);
|
|
||||||
typedef void (*NPN_SetExceptionProcPtr)(NPObject *obj, const NPUTF8 *message);
|
|
||||||
typedef void (*NPN_PushPopupsEnabledStateProcPtr)(NPP npp, NPBool enabled);
|
|
||||||
typedef void (*NPN_PopPopupsEnabledStateProcPtr)(NPP npp);
|
|
||||||
typedef bool (*NPN_EnumerateProcPtr)(NPP npp, NPObject *obj, NPIdentifier **identifier, uint32_t *count);
|
|
||||||
typedef void (*NPN_PluginThreadAsyncCallProcPtr)(NPP instance, void (*func)(void *), void *userData);
|
|
||||||
typedef bool (*NPN_ConstructProcPtr)(NPP npp, NPObject* obj, const NPVariant *args, uint32_t argCount, NPVariant *result);
|
|
||||||
typedef NPError (*NPN_GetValueForURLPtr)(NPP npp, NPNURLVariable variable, const char *url, char **value, uint32_t *len);
|
|
||||||
typedef NPError (*NPN_SetValueForURLPtr)(NPP npp, NPNURLVariable variable, const char *url, const char *value, uint32_t len);
|
|
||||||
typedef NPError (*NPN_GetAuthenticationInfoPtr)(NPP npp, const char *protocol, const char *host, int32_t port, const char *scheme, const char *realm, char **username, uint32_t *ulen, char **password, uint32_t *plen);
|
|
||||||
typedef uint32_t (*NPN_ScheduleTimerPtr)(NPP instance, uint32_t interval, NPBool repeat, void (*timerFunc)(NPP npp, uint32_t timerID));
|
|
||||||
typedef void (*NPN_UnscheduleTimerPtr)(NPP instance, uint32_t timerID);
|
|
||||||
typedef NPError (*NPN_PopUpContextMenuPtr)(NPP instance, NPMenu* menu);
|
|
||||||
typedef NPBool (*NPN_ConvertPointPtr)(NPP instance, double sourceX, double sourceY, NPCoordinateSpace sourceSpace, double *destX, double *destY, NPCoordinateSpace destSpace);
|
|
||||||
typedef NPBool (*NPN_HandleEventPtr)(NPP instance, void *event, NPBool handled);
|
|
||||||
typedef NPBool (*NPN_UnfocusInstancePtr)(NPP instance, NPFocusDirection direction);
|
|
||||||
typedef void (*NPN_URLRedirectResponsePtr)(NPP instance, void* notifyData, NPBool allow);
|
|
||||||
|
|
||||||
typedef struct _NPPluginFuncs {
|
|
||||||
uint16_t size;
|
|
||||||
uint16_t version;
|
|
||||||
NPP_NewProcPtr newp;
|
|
||||||
NPP_DestroyProcPtr destroy;
|
|
||||||
NPP_SetWindowProcPtr setwindow;
|
|
||||||
NPP_NewStreamProcPtr newstream;
|
|
||||||
NPP_DestroyStreamProcPtr destroystream;
|
|
||||||
NPP_StreamAsFileProcPtr asfile;
|
|
||||||
NPP_WriteReadyProcPtr writeready;
|
|
||||||
NPP_WriteProcPtr write;
|
|
||||||
NPP_PrintProcPtr print;
|
|
||||||
NPP_HandleEventProcPtr event;
|
|
||||||
NPP_URLNotifyProcPtr urlnotify;
|
|
||||||
void* javaClass;
|
|
||||||
NPP_GetValueProcPtr getvalue;
|
|
||||||
NPP_SetValueProcPtr setvalue;
|
|
||||||
NPP_GotFocusPtr gotfocus;
|
|
||||||
NPP_LostFocusPtr lostfocus;
|
|
||||||
NPP_URLRedirectNotifyPtr urlredirectnotify;
|
|
||||||
NPP_ClearSiteDataPtr clearsitedata;
|
|
||||||
NPP_GetSitesWithDataPtr getsiteswithdata;
|
|
||||||
} NPPluginFuncs;
|
|
||||||
|
|
||||||
typedef struct _NPNetscapeFuncs {
|
|
||||||
uint16_t size;
|
|
||||||
uint16_t version;
|
|
||||||
NPN_GetURLProcPtr geturl;
|
|
||||||
NPN_PostURLProcPtr posturl;
|
|
||||||
NPN_RequestReadProcPtr requestread;
|
|
||||||
NPN_NewStreamProcPtr newstream;
|
|
||||||
NPN_WriteProcPtr write;
|
|
||||||
NPN_DestroyStreamProcPtr destroystream;
|
|
||||||
NPN_StatusProcPtr status;
|
|
||||||
NPN_UserAgentProcPtr uagent;
|
|
||||||
NPN_MemAllocProcPtr memalloc;
|
|
||||||
NPN_MemFreeProcPtr memfree;
|
|
||||||
NPN_MemFlushProcPtr memflush;
|
|
||||||
NPN_ReloadPluginsProcPtr reloadplugins;
|
|
||||||
NPN_GetJavaEnvProcPtr getJavaEnv;
|
|
||||||
NPN_GetJavaPeerProcPtr getJavaPeer;
|
|
||||||
NPN_GetURLNotifyProcPtr geturlnotify;
|
|
||||||
NPN_PostURLNotifyProcPtr posturlnotify;
|
|
||||||
NPN_GetValueProcPtr getvalue;
|
|
||||||
NPN_SetValueProcPtr setvalue;
|
|
||||||
NPN_InvalidateRectProcPtr invalidaterect;
|
|
||||||
NPN_InvalidateRegionProcPtr invalidateregion;
|
|
||||||
NPN_ForceRedrawProcPtr forceredraw;
|
|
||||||
NPN_GetStringIdentifierProcPtr getstringidentifier;
|
|
||||||
NPN_GetStringIdentifiersProcPtr getstringidentifiers;
|
|
||||||
NPN_GetIntIdentifierProcPtr getintidentifier;
|
|
||||||
NPN_IdentifierIsStringProcPtr identifierisstring;
|
|
||||||
NPN_UTF8FromIdentifierProcPtr utf8fromidentifier;
|
|
||||||
NPN_IntFromIdentifierProcPtr intfromidentifier;
|
|
||||||
NPN_CreateObjectProcPtr createobject;
|
|
||||||
NPN_RetainObjectProcPtr retainobject;
|
|
||||||
NPN_ReleaseObjectProcPtr releaseobject;
|
|
||||||
NPN_InvokeProcPtr invoke;
|
|
||||||
NPN_InvokeDefaultProcPtr invokeDefault;
|
|
||||||
NPN_EvaluateProcPtr evaluate;
|
|
||||||
NPN_GetPropertyProcPtr getproperty;
|
|
||||||
NPN_SetPropertyProcPtr setproperty;
|
|
||||||
NPN_RemovePropertyProcPtr removeproperty;
|
|
||||||
NPN_HasPropertyProcPtr hasproperty;
|
|
||||||
NPN_HasMethodProcPtr hasmethod;
|
|
||||||
NPN_ReleaseVariantValueProcPtr releasevariantvalue;
|
|
||||||
NPN_SetExceptionProcPtr setexception;
|
|
||||||
NPN_PushPopupsEnabledStateProcPtr pushpopupsenabledstate;
|
|
||||||
NPN_PopPopupsEnabledStateProcPtr poppopupsenabledstate;
|
|
||||||
NPN_EnumerateProcPtr enumerate;
|
|
||||||
NPN_PluginThreadAsyncCallProcPtr pluginthreadasynccall;
|
|
||||||
NPN_ConstructProcPtr construct;
|
|
||||||
NPN_GetValueForURLPtr getvalueforurl;
|
|
||||||
NPN_SetValueForURLPtr setvalueforurl;
|
|
||||||
NPN_GetAuthenticationInfoPtr getauthenticationinfo;
|
|
||||||
NPN_ScheduleTimerPtr scheduletimer;
|
|
||||||
NPN_UnscheduleTimerPtr unscheduletimer;
|
|
||||||
NPN_PopUpContextMenuPtr popupcontextmenu;
|
|
||||||
NPN_ConvertPointPtr convertpoint;
|
|
||||||
NPN_HandleEventPtr handleevent;
|
|
||||||
NPN_UnfocusInstancePtr unfocusinstance;
|
|
||||||
NPN_URLRedirectResponsePtr urlredirectresponse;
|
|
||||||
} NPNetscapeFuncs;
|
|
||||||
|
|
||||||
#ifdef XP_MACOSX
|
|
||||||
/*
|
|
||||||
* Mac OS X version(s) of NP_GetMIMEDescription(const char *)
|
|
||||||
* These can be called to retreive MIME information from the plugin dynamically
|
|
||||||
*
|
|
||||||
* Note: For compatibility with Quicktime, BPSupportedMIMEtypes is another way
|
|
||||||
* to get mime info from the plugin only on OSX and may not be supported
|
|
||||||
* in furture version -- use NP_GetMIMEDescription instead
|
|
||||||
*/
|
|
||||||
enum
|
|
||||||
{
|
|
||||||
kBPSupportedMIMETypesStructVers_1 = 1
|
|
||||||
};
|
|
||||||
typedef struct _BPSupportedMIMETypes
|
|
||||||
{
|
|
||||||
SInt32 structVersion; /* struct version */
|
|
||||||
Handle typeStrings; /* STR# formated handle, allocated by plug-in */
|
|
||||||
Handle infoStrings; /* STR# formated handle, allocated by plug-in */
|
|
||||||
} BPSupportedMIMETypes;
|
|
||||||
OSErr BP_GetSupportedMIMETypes(BPSupportedMIMETypes *mimeInfo, UInt32 flags);
|
|
||||||
#define NP_GETMIMEDESCRIPTION_NAME "NP_GetMIMEDescription"
|
|
||||||
typedef const char* (*NP_GetMIMEDescriptionProcPtr)(void);
|
|
||||||
typedef OSErr (*BP_GetSupportedMIMETypesProcPtr)(BPSupportedMIMETypes*, UInt32);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(_WIN32)
|
|
||||||
#define OSCALL WINAPI
|
|
||||||
#else
|
|
||||||
#if defined(__OS2__)
|
|
||||||
#define OSCALL _System
|
|
||||||
#else
|
|
||||||
#define OSCALL
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(XP_UNIX)
|
|
||||||
/* GCC 3.3 and later support the visibility attribute. */
|
|
||||||
#if defined(__GNUC__) && ((__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3))
|
|
||||||
#define NP_VISIBILITY_DEFAULT __attribute__((visibility("default")))
|
|
||||||
#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC)
|
|
||||||
#define NP_VISIBILITY_DEFAULT __global
|
|
||||||
#else
|
|
||||||
#define NP_VISIBILITY_DEFAULT
|
|
||||||
#endif
|
|
||||||
#define NP_EXPORT(__type) NP_VISIBILITY_DEFAULT __type
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(_WIN32) || defined (__OS2__)
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C" {
|
|
||||||
#endif
|
|
||||||
/* plugin meta member functions */
|
|
||||||
#if defined(__OS2__)
|
|
||||||
typedef struct _NPPluginData { /* Alternate OS2 Plugin interface */
|
|
||||||
char *pMimeTypes;
|
|
||||||
char *pFileExtents;
|
|
||||||
char *pFileOpenTemplate;
|
|
||||||
char *pProductName;
|
|
||||||
char *pProductDescription;
|
|
||||||
unsigned long dwProductVersionMS;
|
|
||||||
unsigned long dwProductVersionLS;
|
|
||||||
} NPPluginData;
|
|
||||||
typedef NPError (*NP_GetPluginDataFunc)(NPPluginData*);
|
|
||||||
NPError OSCALL NP_GetPluginData(NPPluginData * pPluginData);
|
|
||||||
#endif
|
|
||||||
typedef NPError (*NP_GetEntryPointsFunc)(NPPluginFuncs*);
|
|
||||||
NPError OSCALL NP_GetEntryPoints(NPPluginFuncs* pFuncs);
|
|
||||||
typedef NPError (*NP_InitializeFunc)(NPNetscapeFuncs*);
|
|
||||||
NPError OSCALL NP_Initialize(NPNetscapeFuncs* bFuncs);
|
|
||||||
typedef NPError (*NP_ShutdownFunc)(void);
|
|
||||||
NPError OSCALL NP_Shutdown(void);
|
|
||||||
typedef const char* (*NP_GetMIMEDescriptionFunc)(void);
|
|
||||||
const char* NP_GetMIMEDescription(void);
|
|
||||||
#ifdef __cplusplus
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(__OS2__)
|
|
||||||
#pragma pack()
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef XP_UNIX
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C" {
|
|
||||||
#endif
|
|
||||||
typedef char* (*NP_GetPluginVersionFunc)(void);
|
|
||||||
NP_EXPORT(char*) NP_GetPluginVersion(void);
|
|
||||||
typedef const char* (*NP_GetMIMEDescriptionFunc)(void);
|
|
||||||
NP_EXPORT(const char*) NP_GetMIMEDescription(void);
|
|
||||||
#ifdef XP_MACOSX
|
|
||||||
typedef NPError (*NP_InitializeFunc)(NPNetscapeFuncs*);
|
|
||||||
NP_EXPORT(NPError) NP_Initialize(NPNetscapeFuncs* bFuncs);
|
|
||||||
typedef NPError (*NP_GetEntryPointsFunc)(NPPluginFuncs*);
|
|
||||||
NP_EXPORT(NPError) NP_GetEntryPoints(NPPluginFuncs* pFuncs);
|
|
||||||
#else
|
|
||||||
typedef NPError (*NP_InitializeFunc)(NPNetscapeFuncs*, NPPluginFuncs*);
|
|
||||||
NP_EXPORT(NPError) NP_Initialize(NPNetscapeFuncs* bFuncs, NPPluginFuncs* pFuncs);
|
|
||||||
#endif
|
|
||||||
typedef NPError (*NP_ShutdownFunc)(void);
|
|
||||||
NP_EXPORT(NPError) NP_Shutdown(void);
|
|
||||||
typedef NPError (*NP_GetValueFunc)(void *, NPPVariable, void *);
|
|
||||||
NP_EXPORT(NPError) NP_GetValue(void *future, NPPVariable aVariable, void *aValue);
|
|
||||||
#ifdef __cplusplus
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* npfunctions_h_ */
|
|
@@ -1,393 +0,0 @@
|
|||||||
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
||||||
/*
|
|
||||||
* Copyright (c) 2004, Apple Computer, Inc. and The Mozilla Foundation.
|
|
||||||
* All rights reserved.
|
|
||||||
*
|
|
||||||
* Redistribution and use in source and binary forms, with or without
|
|
||||||
* modification, are permitted provided that the following conditions are
|
|
||||||
* met:
|
|
||||||
*
|
|
||||||
* 1. Redistributions of source code must retain the above copyright
|
|
||||||
* notice, this list of conditions and the following disclaimer.
|
|
||||||
* 2. Redistributions in binary form must reproduce the above copyright
|
|
||||||
* notice, this list of conditions and the following disclaimer in the
|
|
||||||
* documentation and/or other materials provided with the distribution.
|
|
||||||
* 3. Neither the names of Apple Computer, Inc. ("Apple") or The Mozilla
|
|
||||||
* Foundation ("Mozilla") nor the names of their contributors may be used
|
|
||||||
* to endorse or promote products derived from this software without
|
|
||||||
* specific prior written permission.
|
|
||||||
*
|
|
||||||
* THIS SOFTWARE IS PROVIDED BY APPLE, MOZILLA AND THEIR CONTRIBUTORS "AS
|
|
||||||
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
||||||
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
||||||
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE, MOZILLA OR
|
|
||||||
* THEIR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
||||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
|
|
||||||
* TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
|
||||||
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
|
||||||
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
|
||||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
#ifndef _NP_RUNTIME_H_
|
|
||||||
#define _NP_RUNTIME_H_
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C" {
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "nptypes.h"
|
|
||||||
|
|
||||||
/*
|
|
||||||
This API is used to facilitate binding code written in C to script
|
|
||||||
objects. The API in this header does not assume the presence of a
|
|
||||||
user agent. That is, it can be used to bind C code to scripting
|
|
||||||
environments outside of the context of a user agent.
|
|
||||||
|
|
||||||
However, the normal use of the this API is in the context of a
|
|
||||||
scripting environment running in a browser or other user agent.
|
|
||||||
In particular it is used to support the extended Netscape
|
|
||||||
script-ability API for plugins (NP-SAP). NP-SAP is an extension
|
|
||||||
of the Netscape plugin API. As such we have adopted the use of
|
|
||||||
the "NP" prefix for this API.
|
|
||||||
|
|
||||||
The following NP{N|P}Variables were added to the Netscape plugin
|
|
||||||
API (in npapi.h):
|
|
||||||
|
|
||||||
NPNVWindowNPObject
|
|
||||||
NPNVPluginElementNPObject
|
|
||||||
NPPVpluginScriptableNPObject
|
|
||||||
|
|
||||||
These variables are exposed through NPN_GetValue() and
|
|
||||||
NPP_GetValue() (respectively) and are used to establish the
|
|
||||||
initial binding between the user agent and native code. The DOM
|
|
||||||
objects in the user agent can be examined and manipulated using
|
|
||||||
the NPN_ functions that operate on NPObjects described in this
|
|
||||||
header.
|
|
||||||
|
|
||||||
To the extent possible the assumptions about the scripting
|
|
||||||
language used by the scripting environment have been minimized.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#define NP_BEGIN_MACRO do {
|
|
||||||
#define NP_END_MACRO } while (0)
|
|
||||||
|
|
||||||
/*
|
|
||||||
Objects (non-primitive data) passed between 'C' and script is
|
|
||||||
always wrapped in an NPObject. The 'interface' of an NPObject is
|
|
||||||
described by an NPClass.
|
|
||||||
*/
|
|
||||||
typedef struct NPObject NPObject;
|
|
||||||
typedef struct NPClass NPClass;
|
|
||||||
|
|
||||||
typedef char NPUTF8;
|
|
||||||
typedef struct _NPString {
|
|
||||||
const NPUTF8 *UTF8Characters;
|
|
||||||
uint32_t UTF8Length;
|
|
||||||
} NPString;
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
NPVariantType_Void,
|
|
||||||
NPVariantType_Null,
|
|
||||||
NPVariantType_Bool,
|
|
||||||
NPVariantType_Int32,
|
|
||||||
NPVariantType_Double,
|
|
||||||
NPVariantType_String,
|
|
||||||
NPVariantType_Object
|
|
||||||
} NPVariantType;
|
|
||||||
|
|
||||||
typedef struct _NPVariant {
|
|
||||||
NPVariantType type;
|
|
||||||
union {
|
|
||||||
bool boolValue;
|
|
||||||
int32_t intValue;
|
|
||||||
double doubleValue;
|
|
||||||
NPString stringValue;
|
|
||||||
NPObject *objectValue;
|
|
||||||
} value;
|
|
||||||
} NPVariant;
|
|
||||||
|
|
||||||
/*
|
|
||||||
NPN_ReleaseVariantValue is called on all 'out' parameters
|
|
||||||
references. Specifically it is to be called on variants that own
|
|
||||||
their value, as is the case with all non-const NPVariant*
|
|
||||||
arguments after a successful call to any methods (except this one)
|
|
||||||
in this API.
|
|
||||||
|
|
||||||
After calling NPN_ReleaseVariantValue, the type of the variant
|
|
||||||
will be NPVariantType_Void.
|
|
||||||
*/
|
|
||||||
void NPN_ReleaseVariantValue(NPVariant *variant);
|
|
||||||
|
|
||||||
#define NPVARIANT_IS_VOID(_v) ((_v).type == NPVariantType_Void)
|
|
||||||
#define NPVARIANT_IS_NULL(_v) ((_v).type == NPVariantType_Null)
|
|
||||||
#define NPVARIANT_IS_BOOLEAN(_v) ((_v).type == NPVariantType_Bool)
|
|
||||||
#define NPVARIANT_IS_INT32(_v) ((_v).type == NPVariantType_Int32)
|
|
||||||
#define NPVARIANT_IS_DOUBLE(_v) ((_v).type == NPVariantType_Double)
|
|
||||||
#define NPVARIANT_IS_STRING(_v) ((_v).type == NPVariantType_String)
|
|
||||||
#define NPVARIANT_IS_OBJECT(_v) ((_v).type == NPVariantType_Object)
|
|
||||||
|
|
||||||
#define NPVARIANT_TO_BOOLEAN(_v) ((_v).value.boolValue)
|
|
||||||
#define NPVARIANT_TO_INT32(_v) ((_v).value.intValue)
|
|
||||||
#define NPVARIANT_TO_DOUBLE(_v) ((_v).value.doubleValue)
|
|
||||||
#define NPVARIANT_TO_STRING(_v) ((_v).value.stringValue)
|
|
||||||
#define NPVARIANT_TO_OBJECT(_v) ((_v).value.objectValue)
|
|
||||||
|
|
||||||
#define VOID_TO_NPVARIANT(_v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Void; \
|
|
||||||
(_v).value.objectValue = NULL; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define NULL_TO_NPVARIANT(_v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Null; \
|
|
||||||
(_v).value.objectValue = NULL; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define BOOLEAN_TO_NPVARIANT(_val, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Bool; \
|
|
||||||
(_v).value.boolValue = !!(_val); \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define INT32_TO_NPVARIANT(_val, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Int32; \
|
|
||||||
(_v).value.intValue = _val; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define DOUBLE_TO_NPVARIANT(_val, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Double; \
|
|
||||||
(_v).value.doubleValue = _val; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define STRINGZ_TO_NPVARIANT(_val, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_String; \
|
|
||||||
NPString str = { _val, (uint32_t)(strlen(_val)) }; \
|
|
||||||
(_v).value.stringValue = str; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define STRINGN_TO_NPVARIANT(_val, _len, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_String; \
|
|
||||||
NPString str = { _val, (uint32_t)(_len) }; \
|
|
||||||
(_v).value.stringValue = str; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
#define OBJECT_TO_NPVARIANT(_val, _v) \
|
|
||||||
NP_BEGIN_MACRO \
|
|
||||||
(_v).type = NPVariantType_Object; \
|
|
||||||
(_v).value.objectValue = _val; \
|
|
||||||
NP_END_MACRO
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
Type mappings (JavaScript types have been used for illustration
|
|
||||||
purposes):
|
|
||||||
|
|
||||||
JavaScript to C (NPVariant with type:)
|
|
||||||
undefined NPVariantType_Void
|
|
||||||
null NPVariantType_Null
|
|
||||||
Boolean NPVariantType_Bool
|
|
||||||
Number NPVariantType_Double or NPVariantType_Int32
|
|
||||||
String NPVariantType_String
|
|
||||||
Object NPVariantType_Object
|
|
||||||
|
|
||||||
C (NPVariant with type:) to JavaScript
|
|
||||||
NPVariantType_Void undefined
|
|
||||||
NPVariantType_Null null
|
|
||||||
NPVariantType_Bool Boolean
|
|
||||||
NPVariantType_Int32 Number
|
|
||||||
NPVariantType_Double Number
|
|
||||||
NPVariantType_String String
|
|
||||||
NPVariantType_Object Object
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef void *NPIdentifier;
|
|
||||||
|
|
||||||
/*
|
|
||||||
NPObjects have methods and properties. Methods and properties are
|
|
||||||
identified with NPIdentifiers. These identifiers may be reflected
|
|
||||||
in script. NPIdentifiers can be either strings or integers, IOW,
|
|
||||||
methods and properties can be identified by either strings or
|
|
||||||
integers (i.e. foo["bar"] vs foo[1]). NPIdentifiers can be
|
|
||||||
compared using ==. In case of any errors, the requested
|
|
||||||
NPIdentifier(s) will be NULL. NPIdentifier lifetime is controlled
|
|
||||||
by the browser. Plugins do not need to worry about memory management
|
|
||||||
with regards to NPIdentifiers.
|
|
||||||
*/
|
|
||||||
NPIdentifier NPN_GetStringIdentifier(const NPUTF8 *name);
|
|
||||||
void NPN_GetStringIdentifiers(const NPUTF8 **names, int32_t nameCount,
|
|
||||||
NPIdentifier *identifiers);
|
|
||||||
NPIdentifier NPN_GetIntIdentifier(int32_t intid);
|
|
||||||
bool NPN_IdentifierIsString(NPIdentifier identifier);
|
|
||||||
|
|
||||||
/*
|
|
||||||
The NPUTF8 returned from NPN_UTF8FromIdentifier SHOULD be freed.
|
|
||||||
*/
|
|
||||||
NPUTF8 *NPN_UTF8FromIdentifier(NPIdentifier identifier);
|
|
||||||
|
|
||||||
/*
|
|
||||||
Get the integer represented by identifier. If identifier is not an
|
|
||||||
integer identifier, the behaviour is undefined.
|
|
||||||
*/
|
|
||||||
int32_t NPN_IntFromIdentifier(NPIdentifier identifier);
|
|
||||||
|
|
||||||
/*
|
|
||||||
NPObject behavior is implemented using the following set of
|
|
||||||
callback functions.
|
|
||||||
|
|
||||||
The NPVariant *result argument of these functions (where
|
|
||||||
applicable) should be released using NPN_ReleaseVariantValue().
|
|
||||||
*/
|
|
||||||
typedef NPObject *(*NPAllocateFunctionPtr)(NPP npp, NPClass *aClass);
|
|
||||||
typedef void (*NPDeallocateFunctionPtr)(NPObject *npobj);
|
|
||||||
typedef void (*NPInvalidateFunctionPtr)(NPObject *npobj);
|
|
||||||
typedef bool (*NPHasMethodFunctionPtr)(NPObject *npobj, NPIdentifier name);
|
|
||||||
typedef bool (*NPInvokeFunctionPtr)(NPObject *npobj, NPIdentifier name,
|
|
||||||
const NPVariant *args, uint32_t argCount,
|
|
||||||
NPVariant *result);
|
|
||||||
typedef bool (*NPInvokeDefaultFunctionPtr)(NPObject *npobj,
|
|
||||||
const NPVariant *args,
|
|
||||||
uint32_t argCount,
|
|
||||||
NPVariant *result);
|
|
||||||
typedef bool (*NPHasPropertyFunctionPtr)(NPObject *npobj, NPIdentifier name);
|
|
||||||
typedef bool (*NPGetPropertyFunctionPtr)(NPObject *npobj, NPIdentifier name,
|
|
||||||
NPVariant *result);
|
|
||||||
typedef bool (*NPSetPropertyFunctionPtr)(NPObject *npobj, NPIdentifier name,
|
|
||||||
const NPVariant *value);
|
|
||||||
typedef bool (*NPRemovePropertyFunctionPtr)(NPObject *npobj,
|
|
||||||
NPIdentifier name);
|
|
||||||
typedef bool (*NPEnumerationFunctionPtr)(NPObject *npobj, NPIdentifier **value,
|
|
||||||
uint32_t *count);
|
|
||||||
typedef bool (*NPConstructFunctionPtr)(NPObject *npobj,
|
|
||||||
const NPVariant *args,
|
|
||||||
uint32_t argCount,
|
|
||||||
NPVariant *result);
|
|
||||||
|
|
||||||
/*
|
|
||||||
NPObjects returned by create, retain, invoke, and getProperty pass
|
|
||||||
a reference count to the caller. That is, the callee adds a
|
|
||||||
reference count which passes to the caller. It is the caller's
|
|
||||||
responsibility to release the returned object.
|
|
||||||
|
|
||||||
NPInvokeFunctionPtr function may return 0 to indicate a void
|
|
||||||
result.
|
|
||||||
|
|
||||||
NPInvalidateFunctionPtr is called by the scripting environment
|
|
||||||
when the native code is shutdown. Any attempt to message a
|
|
||||||
NPObject instance after the invalidate callback has been
|
|
||||||
called will result in undefined behavior, even if the native code
|
|
||||||
is still retaining those NPObject instances. (The runtime
|
|
||||||
will typically return immediately, with 0 or NULL, from an attempt
|
|
||||||
to dispatch to a NPObject, but this behavior should not be
|
|
||||||
depended upon.)
|
|
||||||
|
|
||||||
The NPEnumerationFunctionPtr function may pass an array of
|
|
||||||
NPIdentifiers back to the caller. The callee allocs the memory of
|
|
||||||
the array using NPN_MemAlloc(), and it's the caller's responsibility
|
|
||||||
to release it using NPN_MemFree().
|
|
||||||
*/
|
|
||||||
struct NPClass
|
|
||||||
{
|
|
||||||
uint32_t structVersion;
|
|
||||||
NPAllocateFunctionPtr allocate;
|
|
||||||
NPDeallocateFunctionPtr deallocate;
|
|
||||||
NPInvalidateFunctionPtr invalidate;
|
|
||||||
NPHasMethodFunctionPtr hasMethod;
|
|
||||||
NPInvokeFunctionPtr invoke;
|
|
||||||
NPInvokeDefaultFunctionPtr invokeDefault;
|
|
||||||
NPHasPropertyFunctionPtr hasProperty;
|
|
||||||
NPGetPropertyFunctionPtr getProperty;
|
|
||||||
NPSetPropertyFunctionPtr setProperty;
|
|
||||||
NPRemovePropertyFunctionPtr removeProperty;
|
|
||||||
NPEnumerationFunctionPtr enumerate;
|
|
||||||
NPConstructFunctionPtr construct;
|
|
||||||
};
|
|
||||||
|
|
||||||
#define NP_CLASS_STRUCT_VERSION 3
|
|
||||||
|
|
||||||
#define NP_CLASS_STRUCT_VERSION_ENUM 2
|
|
||||||
#define NP_CLASS_STRUCT_VERSION_CTOR 3
|
|
||||||
|
|
||||||
#define NP_CLASS_STRUCT_VERSION_HAS_ENUM(npclass) \
|
|
||||||
((npclass)->structVersion >= NP_CLASS_STRUCT_VERSION_ENUM)
|
|
||||||
|
|
||||||
#define NP_CLASS_STRUCT_VERSION_HAS_CTOR(npclass) \
|
|
||||||
((npclass)->structVersion >= NP_CLASS_STRUCT_VERSION_CTOR)
|
|
||||||
|
|
||||||
struct NPObject {
|
|
||||||
NPClass *_class;
|
|
||||||
uint32_t referenceCount;
|
|
||||||
/*
|
|
||||||
* Additional space may be allocated here by types of NPObjects
|
|
||||||
*/
|
|
||||||
};
|
|
||||||
|
|
||||||
/*
|
|
||||||
If the class has an allocate function, NPN_CreateObject invokes
|
|
||||||
that function, otherwise a NPObject is allocated and
|
|
||||||
returned. This method will initialize the referenceCount member of
|
|
||||||
the NPObject to 1.
|
|
||||||
*/
|
|
||||||
NPObject *NPN_CreateObject(NPP npp, NPClass *aClass);
|
|
||||||
|
|
||||||
/*
|
|
||||||
Increment the NPObject's reference count.
|
|
||||||
*/
|
|
||||||
NPObject *NPN_RetainObject(NPObject *npobj);
|
|
||||||
|
|
||||||
/*
|
|
||||||
Decremented the NPObject's reference count. If the reference
|
|
||||||
count goes to zero, the class's destroy function is invoke if
|
|
||||||
specified, otherwise the object is freed directly.
|
|
||||||
*/
|
|
||||||
void NPN_ReleaseObject(NPObject *npobj);
|
|
||||||
|
|
||||||
/*
|
|
||||||
Functions to access script objects represented by NPObject.
|
|
||||||
|
|
||||||
Calls to script objects are synchronous. If a function returns a
|
|
||||||
value, it will be supplied via the result NPVariant
|
|
||||||
argument. Successful calls will return true, false will be
|
|
||||||
returned in case of an error.
|
|
||||||
|
|
||||||
Calls made from plugin code to script must be made from the thread
|
|
||||||
on which the plugin was initialized.
|
|
||||||
*/
|
|
||||||
|
|
||||||
bool NPN_Invoke(NPP npp, NPObject *npobj, NPIdentifier methodName,
|
|
||||||
const NPVariant *args, uint32_t argCount, NPVariant *result);
|
|
||||||
bool NPN_InvokeDefault(NPP npp, NPObject *npobj, const NPVariant *args,
|
|
||||||
uint32_t argCount, NPVariant *result);
|
|
||||||
bool NPN_Evaluate(NPP npp, NPObject *npobj, NPString *script,
|
|
||||||
NPVariant *result);
|
|
||||||
bool NPN_GetProperty(NPP npp, NPObject *npobj, NPIdentifier propertyName,
|
|
||||||
NPVariant *result);
|
|
||||||
bool NPN_SetProperty(NPP npp, NPObject *npobj, NPIdentifier propertyName,
|
|
||||||
const NPVariant *value);
|
|
||||||
bool NPN_RemoveProperty(NPP npp, NPObject *npobj, NPIdentifier propertyName);
|
|
||||||
bool NPN_HasProperty(NPP npp, NPObject *npobj, NPIdentifier propertyName);
|
|
||||||
bool NPN_HasMethod(NPP npp, NPObject *npobj, NPIdentifier methodName);
|
|
||||||
bool NPN_Enumerate(NPP npp, NPObject *npobj, NPIdentifier **identifier,
|
|
||||||
uint32_t *count);
|
|
||||||
bool NPN_Construct(NPP npp, NPObject *npobj, const NPVariant *args,
|
|
||||||
uint32_t argCount, NPVariant *result);
|
|
||||||
|
|
||||||
/*
|
|
||||||
NPN_SetException may be called to trigger a script exception upon
|
|
||||||
return from entry points into NPObjects. Typical usage:
|
|
||||||
|
|
||||||
NPN_SetException (npobj, message);
|
|
||||||
*/
|
|
||||||
void NPN_SetException(NPObject *npobj, const NPUTF8 *message);
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif
|
|
@@ -1,121 +0,0 @@
|
|||||||
/* -*- Mode: C; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
||||||
/* ***** BEGIN LICENSE BLOCK *****
|
|
||||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
|
||||||
*
|
|
||||||
* The contents of this file are subject to the Mozilla Public License Version
|
|
||||||
* 1.1 (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.mozilla.org/MPL/
|
|
||||||
*
|
|
||||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
|
||||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
|
||||||
* for the specific language governing rights and limitations under the
|
|
||||||
* License.
|
|
||||||
*
|
|
||||||
* The Original Code is mozilla.org code.
|
|
||||||
*
|
|
||||||
* The Initial Developer of the Original Code is
|
|
||||||
* mozilla.org.
|
|
||||||
* Portions created by the Initial Developer are Copyright (C) 2004
|
|
||||||
* the Initial Developer. All Rights Reserved.
|
|
||||||
*
|
|
||||||
* Contributor(s):
|
|
||||||
* Johnny Stenback <jst@mozilla.org> (Original author)
|
|
||||||
*
|
|
||||||
* Alternatively, the contents of this file may be used under the terms of
|
|
||||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
|
||||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
|
||||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
|
||||||
* of those above. If you wish to allow use of your version of this file only
|
|
||||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
|
||||||
* use your version of this file under the terms of the MPL, indicate your
|
|
||||||
* decision by deleting the provisions above and replace them with the notice
|
|
||||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
|
||||||
* the provisions above, a recipient may use your version of this file under
|
|
||||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
|
||||||
*
|
|
||||||
* ***** END LICENSE BLOCK ***** */
|
|
||||||
|
|
||||||
#ifndef nptypes_h_
|
|
||||||
#define nptypes_h_
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Header file for ensuring that C99 types ([u]int32_t, [u]int64_t and bool) and
|
|
||||||
* true/false macros are available.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#if defined(WIN32) || defined(OS2)
|
|
||||||
/*
|
|
||||||
* Win32 and OS/2 don't know C99, so define [u]int_16/32/64 here. The bool
|
|
||||||
* is predefined tho, both in C and C++.
|
|
||||||
*/
|
|
||||||
typedef short int16_t;
|
|
||||||
typedef unsigned short uint16_t;
|
|
||||||
typedef int int32_t;
|
|
||||||
typedef unsigned int uint32_t;
|
|
||||||
typedef long long int64_t;
|
|
||||||
typedef unsigned long long uint64_t;
|
|
||||||
#elif defined(_AIX) || defined(__sun) || defined(__osf__) || defined(IRIX) || defined(HPUX)
|
|
||||||
/*
|
|
||||||
* AIX and SunOS ship a inttypes.h header that defines [u]int32_t,
|
|
||||||
* but not bool for C.
|
|
||||||
*/
|
|
||||||
#include <inttypes.h>
|
|
||||||
|
|
||||||
#ifndef __cplusplus
|
|
||||||
typedef int bool;
|
|
||||||
#define true 1
|
|
||||||
#define false 0
|
|
||||||
#endif
|
|
||||||
#elif defined(bsdi) || defined(FREEBSD) || defined(OPENBSD)
|
|
||||||
/*
|
|
||||||
* BSD/OS, FreeBSD, and OpenBSD ship sys/types.h that define int32_t and
|
|
||||||
* u_int32_t.
|
|
||||||
*/
|
|
||||||
#include <sys/types.h>
|
|
||||||
|
|
||||||
/*
|
|
||||||
* BSD/OS ships no header that defines uint32_t, nor bool (for C)
|
|
||||||
*/
|
|
||||||
#if defined(bsdi)
|
|
||||||
typedef u_int32_t uint32_t;
|
|
||||||
typedef u_int64_t uint64_t;
|
|
||||||
|
|
||||||
#if !defined(__cplusplus)
|
|
||||||
typedef int bool;
|
|
||||||
#define true 1
|
|
||||||
#define false 0
|
|
||||||
#endif
|
|
||||||
#else
|
|
||||||
/*
|
|
||||||
* FreeBSD and OpenBSD define uint32_t and bool.
|
|
||||||
*/
|
|
||||||
#include <inttypes.h>
|
|
||||||
#include <stdbool.h>
|
|
||||||
#endif
|
|
||||||
#elif defined(BEOS)
|
|
||||||
#include <inttypes.h>
|
|
||||||
#else
|
|
||||||
/*
|
|
||||||
* For those that ship a standard C99 stdint.h header file, include
|
|
||||||
* it. Can't do the same for stdbool.h tho, since some systems ship
|
|
||||||
* with a stdbool.h file that doesn't compile!
|
|
||||||
*/
|
|
||||||
#include <stdint.h>
|
|
||||||
|
|
||||||
#ifndef __cplusplus
|
|
||||||
#if !defined(__GNUC__) || (__GNUC__ > 2 || __GNUC_MINOR__ > 95)
|
|
||||||
#include <stdbool.h>
|
|
||||||
#else
|
|
||||||
/*
|
|
||||||
* GCC 2.91 can't deal with a typedef for bool, but a #define
|
|
||||||
* works.
|
|
||||||
*/
|
|
||||||
#define bool int
|
|
||||||
#define true 1
|
|
||||||
#define false 0
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* nptypes_h_ */
|
|
@@ -1,18 +1,11 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<gresources>
|
<gresources>
|
||||||
<gresource prefix="/org/gnome/shell/theme">
|
<gresource prefix="/org/gnome/shell/theme">
|
||||||
<file>calendar-arrow-left.svg</file>
|
|
||||||
<file>calendar-arrow-right.svg</file>
|
|
||||||
<file>calendar-today.svg</file>
|
<file>calendar-today.svg</file>
|
||||||
<file>checkbox-focused.svg</file>
|
<file>checkbox-focused.svg</file>
|
||||||
<file>checkbox-off-focused.svg</file>
|
<file>checkbox-off-focused.svg</file>
|
||||||
<file>checkbox-off.svg</file>
|
<file>checkbox-off.svg</file>
|
||||||
<file>checkbox.svg</file>
|
<file>checkbox.svg</file>
|
||||||
<file>close-window.svg</file>
|
|
||||||
<file>close-window-active.svg</file>
|
|
||||||
<file>close-window-hover.svg</file>
|
|
||||||
<file>corner-ripple-ltr.png</file>
|
|
||||||
<file>corner-ripple-rtl.png</file>
|
|
||||||
<file>dash-placeholder.svg</file>
|
<file>dash-placeholder.svg</file>
|
||||||
<file>gnome-shell.css</file>
|
<file>gnome-shell.css</file>
|
||||||
<file>gnome-shell-high-contrast.css</file>
|
<file>gnome-shell-high-contrast.css</file>
|
||||||
@@ -27,10 +20,6 @@
|
|||||||
<file>no-notifications.svg</file>
|
<file>no-notifications.svg</file>
|
||||||
<file>noise-texture.png</file>
|
<file>noise-texture.png</file>
|
||||||
<file>pad-osd.css</file>
|
<file>pad-osd.css</file>
|
||||||
<file>page-indicator-active.svg</file>
|
|
||||||
<file>page-indicator-inactive.svg</file>
|
|
||||||
<file>page-indicator-checked.svg</file>
|
|
||||||
<file>page-indicator-hover.svg</file>
|
|
||||||
<file>process-working.svg</file>
|
<file>process-working.svg</file>
|
||||||
<file>toggle-off-us.svg</file>
|
<file>toggle-off-us.svg</file>
|
||||||
<file>toggle-off-intl.svg</file>
|
<file>toggle-off-intl.svg</file>
|
||||||
|
@@ -1,82 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="16"
|
|
||||||
height="16"
|
|
||||||
id="svg2"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48+devel r9942 custom"
|
|
||||||
sodipodi:docname="New document 4">
|
|
||||||
<defs
|
|
||||||
id="defs4" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0.0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="1"
|
|
||||||
inkscape:cx="8.984481"
|
|
||||||
inkscape:cy="5.6224906"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="false"
|
|
||||||
borderlayer="true"
|
|
||||||
inkscape:showpageshadow="false"
|
|
||||||
inkscape:window-width="930"
|
|
||||||
inkscape:window-height="681"
|
|
||||||
inkscape:window-x="1892"
|
|
||||||
inkscape:window-y="272"
|
|
||||||
inkscape:window-maximized="0">
|
|
||||||
<inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid17403"
|
|
||||||
empspacing="5"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" />
|
|
||||||
</sodipodi:namedview>
|
|
||||||
<metadata
|
|
||||||
id="metadata7">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
id="layer1"
|
|
||||||
transform="translate(0,-1036.3622)">
|
|
||||||
<path
|
|
||||||
sodipodi:type="star"
|
|
||||||
style="fill:#5f5f5f;fill-opacity:1;stroke:#5f5f5f;stroke-width:0.43015847;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;display:inline"
|
|
||||||
id="path18028"
|
|
||||||
sodipodi:sides="3"
|
|
||||||
sodipodi:cx="84.5"
|
|
||||||
sodipodi:cy="337.5"
|
|
||||||
sodipodi:r1="5"
|
|
||||||
sodipodi:r2="2.5"
|
|
||||||
sodipodi:arg1="0.52359878"
|
|
||||||
sodipodi:arg2="1.5707963"
|
|
||||||
inkscape:flatsided="true"
|
|
||||||
inkscape:rounded="0"
|
|
||||||
inkscape:randomized="0"
|
|
||||||
d="M 88.830127,340 80.169873,340 84.5,332.5 z"
|
|
||||||
transform="matrix(0,1.3621708,0.99186247,0,-325.48222,929.32667)" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.5 KiB |
@@ -1,82 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="16"
|
|
||||||
height="16"
|
|
||||||
id="svg2"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48+devel r9942 custom"
|
|
||||||
sodipodi:docname="arrow-left.svg">
|
|
||||||
<defs
|
|
||||||
id="defs4" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0.0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="1"
|
|
||||||
inkscape:cx="7.7366092"
|
|
||||||
inkscape:cy="6.4536271"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="false"
|
|
||||||
borderlayer="true"
|
|
||||||
inkscape:showpageshadow="false"
|
|
||||||
inkscape:window-width="930"
|
|
||||||
inkscape:window-height="681"
|
|
||||||
inkscape:window-x="1892"
|
|
||||||
inkscape:window-y="272"
|
|
||||||
inkscape:window-maximized="0">
|
|
||||||
<inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid17403"
|
|
||||||
empspacing="5"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" />
|
|
||||||
</sodipodi:namedview>
|
|
||||||
<metadata
|
|
||||||
id="metadata7">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
id="layer1"
|
|
||||||
transform="translate(0,-1036.3622)">
|
|
||||||
<path
|
|
||||||
sodipodi:type="star"
|
|
||||||
style="fill:#5f5f5f;fill-opacity:1;stroke:#5f5f5f;stroke-width:0.43015847;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;display:inline"
|
|
||||||
id="path18028"
|
|
||||||
sodipodi:sides="3"
|
|
||||||
sodipodi:cx="84.5"
|
|
||||||
sodipodi:cy="337.5"
|
|
||||||
sodipodi:r1="5"
|
|
||||||
sodipodi:r2="2.5"
|
|
||||||
sodipodi:arg1="0.52359878"
|
|
||||||
sodipodi:arg2="1.5707963"
|
|
||||||
inkscape:flatsided="true"
|
|
||||||
inkscape:rounded="0"
|
|
||||||
inkscape:randomized="0"
|
|
||||||
d="M 88.830127,340 80.169873,340 84.5,332.5 z"
|
|
||||||
transform="matrix(0,1.3621708,-0.99186247,0,342.48324,929.32667)" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.5 KiB |
@@ -1,81 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Generator: Adobe Illustrator 13.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 14948) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
version="1.0"
|
|
||||||
id="Foreground"
|
|
||||||
x="0px"
|
|
||||||
y="0px"
|
|
||||||
width="32"
|
|
||||||
height="32"
|
|
||||||
viewBox="0 0 32 32"
|
|
||||||
enable-background="new 0 0 16 16"
|
|
||||||
xml:space="preserve"
|
|
||||||
sodipodi:version="0.32"
|
|
||||||
inkscape:version="0.92.2 5c3e80d, 2017-08-06"
|
|
||||||
sodipodi:docname="close-window-active.svg"
|
|
||||||
inkscape:output_extension="org.inkscape.output.svg.inkscape"><metadata
|
|
||||||
id="metadata2399"><rdf:RDF><cc:Work
|
|
||||||
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
|
|
||||||
id="defs2397"><linearGradient
|
|
||||||
id="linearGradient3173"><stop
|
|
||||||
style="stop-color:#c4c4c4;stop-opacity:1;"
|
|
||||||
offset="0"
|
|
||||||
id="stop3175" /><stop
|
|
||||||
style="stop-color:#ffffff;stop-opacity:1;"
|
|
||||||
offset="1"
|
|
||||||
id="stop3177" /></linearGradient><inkscape:perspective
|
|
||||||
sodipodi:type="inkscape:persp3d"
|
|
||||||
inkscape:vp_x="0 : 11 : 1"
|
|
||||||
inkscape:vp_y="0 : 1375 : 0"
|
|
||||||
inkscape:vp_z="22 : 11 : 1"
|
|
||||||
inkscape:persp3d-origin="11 : 7.3333334 : 1"
|
|
||||||
id="perspective2401" /></defs><sodipodi:namedview
|
|
||||||
inkscape:window-height="1106"
|
|
||||||
inkscape:window-width="1700"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
guidetolerance="10.0"
|
|
||||||
gridtolerance="10.0"
|
|
||||||
objecttolerance="10.0"
|
|
||||||
borderopacity="1.0"
|
|
||||||
bordercolor="#666666"
|
|
||||||
pagecolor="#797979"
|
|
||||||
id="base"
|
|
||||||
showgrid="false"
|
|
||||||
inkscape:zoom="4"
|
|
||||||
inkscape:cx="28.483745"
|
|
||||||
inkscape:cy="67.714004"
|
|
||||||
inkscape:window-x="1427"
|
|
||||||
inkscape:window-y="127"
|
|
||||||
inkscape:current-layer="Foreground"
|
|
||||||
showguides="true"
|
|
||||||
inkscape:guide-bbox="true"
|
|
||||||
borderlayer="true"
|
|
||||||
inkscape:showpageshadow="false"
|
|
||||||
inkscape:window-maximized="0"
|
|
||||||
inkscape:document-rotation="0"><inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid11246"
|
|
||||||
empspacing="32"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" /></sodipodi:namedview><path
|
|
||||||
d="m 4.4362021,16 c 0,-6.410121 5.1728276,-11.60728 11.5529359,-11.60728 6.380109,0 11.552937,5.197159 11.552937,11.60728 0,6.410122 -5.172828,11.607281 -11.552937,11.607281 C 9.6090297,27.607281 4.4362021,22.410122 4.4362021,16 Z"
|
|
||||||
id="path883"
|
|
||||||
style="color:#000000;clip-rule:evenodd;display:inline;overflow:visible;visibility:visible;fill:#a5c8ec;fill-opacity:1;fill-rule:nonzero;stroke:#2975c4;stroke-width:4;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate"
|
|
||||||
sodipodi:nodetypes="csssc"
|
|
||||||
inkscape:connector-curvature="0" /><path
|
|
||||||
d="m 11.718386,11.764547 h 1.055207 c 0.01091,-1.26e-4 0.02193,-4.86e-4 0.03298,0 0.269026,0.01183 0.538019,0.135679 0.725455,0.329752 l 2.407192,2.407192 2.440166,-2.407192 c 0.28029,-0.243226 0.471333,-0.322366 0.725455,-0.329752 h 1.055207 v 1.055208 c 0,0.302285 -0.03623,0.581049 -0.263801,0.791405 l -2.407191,2.407191 2.374217,2.374216 c 0.198577,0.198559 0.296768,0.478484 0.296775,0.758432 v 1.055206 h -1.055211 c -0.279947,-10e-6 -0.559877,-0.09824 -0.75843,-0.296777 l -2.407192,-2.407192 -2.407192,2.407192 c -0.198551,0.198579 -0.478493,0.296777 -0.758429,0.296777 H 11.71839 v -1.055206 c -3e-6,-0.279936 0.0982,-0.559873 0.296777,-0.758432 L 14.422359,16.018351 12.015167,13.61116 C 11.79279,13.405784 11.69527,13.116003 11.71839,12.819755 Z"
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
id="path887"
|
|
||||||
style="color:#bebebe;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:'Andale Mono';-inkscape-font-specification:'Andale Mono';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-anchor:start;display:inline;overflow:visible;visibility:visible;fill:#4a90d9;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.87958801;marker:none;enable-background:new"
|
|
||||||
sodipodi:nodetypes="ccsccccccccccccccccccccccc" /></svg>
|
|
Before Width: | Height: | Size: 4.6 KiB |
@@ -1,81 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Generator: Adobe Illustrator 13.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 14948) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
version="1.0"
|
|
||||||
id="Foreground"
|
|
||||||
x="0px"
|
|
||||||
y="0px"
|
|
||||||
width="32"
|
|
||||||
height="32"
|
|
||||||
viewBox="0 0 32 32"
|
|
||||||
enable-background="new 0 0 16 16"
|
|
||||||
xml:space="preserve"
|
|
||||||
sodipodi:version="0.32"
|
|
||||||
inkscape:version="0.92.2 5c3e80d, 2017-08-06"
|
|
||||||
sodipodi:docname="close-window-hover.svg"
|
|
||||||
inkscape:output_extension="org.inkscape.output.svg.inkscape"><metadata
|
|
||||||
id="metadata2399"><rdf:RDF><cc:Work
|
|
||||||
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title /></cc:Work></rdf:RDF></metadata><defs
|
|
||||||
id="defs2397"><linearGradient
|
|
||||||
id="linearGradient3173"><stop
|
|
||||||
style="stop-color:#c4c4c4;stop-opacity:1;"
|
|
||||||
offset="0"
|
|
||||||
id="stop3175" /><stop
|
|
||||||
style="stop-color:#ffffff;stop-opacity:1;"
|
|
||||||
offset="1"
|
|
||||||
id="stop3177" /></linearGradient><inkscape:perspective
|
|
||||||
sodipodi:type="inkscape:persp3d"
|
|
||||||
inkscape:vp_x="0 : 11 : 1"
|
|
||||||
inkscape:vp_y="0 : 1375 : 0"
|
|
||||||
inkscape:vp_z="22 : 11 : 1"
|
|
||||||
inkscape:persp3d-origin="11 : 7.3333334 : 1"
|
|
||||||
id="perspective2401" /></defs><sodipodi:namedview
|
|
||||||
inkscape:window-height="1106"
|
|
||||||
inkscape:window-width="1700"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
guidetolerance="10.0"
|
|
||||||
gridtolerance="10.0"
|
|
||||||
objecttolerance="10.0"
|
|
||||||
borderopacity="1.0"
|
|
||||||
bordercolor="#666666"
|
|
||||||
pagecolor="#797979"
|
|
||||||
id="base"
|
|
||||||
showgrid="false"
|
|
||||||
inkscape:zoom="4"
|
|
||||||
inkscape:cx="28.483745"
|
|
||||||
inkscape:cy="67.714004"
|
|
||||||
inkscape:window-x="1427"
|
|
||||||
inkscape:window-y="127"
|
|
||||||
inkscape:current-layer="Foreground"
|
|
||||||
showguides="true"
|
|
||||||
inkscape:guide-bbox="true"
|
|
||||||
borderlayer="true"
|
|
||||||
inkscape:showpageshadow="false"
|
|
||||||
inkscape:window-maximized="0"
|
|
||||||
inkscape:document-rotation="0"><inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid11246"
|
|
||||||
empspacing="32"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" /></sodipodi:namedview><path
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
sodipodi:nodetypes="csssc"
|
|
||||||
style="color:#000000;clip-rule:evenodd;display:inline;overflow:visible;visibility:visible;fill:#2975c4;fill-opacity:1;fill-rule:nonzero;stroke:#ffffff;stroke-width:4;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate"
|
|
||||||
id="path822"
|
|
||||||
d="m 4.4362021,16 c 0,-6.410121 5.1728276,-11.60728 11.5529359,-11.60728 6.380109,0 11.552937,5.197159 11.552937,11.60728 0,6.410122 -5.172828,11.607281 -11.552937,11.607281 C 9.6090297,27.607281 4.4362021,22.410122 4.4362021,16 Z" /><path
|
|
||||||
sodipodi:nodetypes="ccsccccccccccccccccccccccc"
|
|
||||||
style="color:#bebebe;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:'Andale Mono';-inkscape-font-specification:'Andale Mono';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-anchor:start;display:inline;overflow:visible;visibility:visible;fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.87958801;marker:none;enable-background:new"
|
|
||||||
id="path826"
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
d="m 11.718386,11.764547 h 1.055207 c 0.01091,-1.26e-4 0.02193,-4.86e-4 0.03298,0 0.269026,0.01183 0.538019,0.135679 0.725455,0.329752 l 2.407192,2.407192 2.440166,-2.407192 c 0.28029,-0.243226 0.471333,-0.322366 0.725455,-0.329752 h 1.055207 v 1.055208 c 0,0.302285 -0.03623,0.581049 -0.263801,0.791405 l -2.407191,2.407191 2.374217,2.374216 c 0.198577,0.198559 0.296768,0.478484 0.296775,0.758432 v 1.055206 h -1.055211 c -0.279947,-10e-6 -0.559877,-0.09824 -0.75843,-0.296777 l -2.407192,-2.407192 -2.407192,2.407192 c -0.198551,0.198579 -0.478493,0.296777 -0.758429,0.296777 H 11.71839 v -1.055206 c -3e-6,-0.279936 0.0982,-0.559873 0.296777,-0.758432 L 14.422359,16.018351 12.015167,13.61116 C 11.79279,13.405784 11.69527,13.116003 11.71839,12.819755 Z" /></svg>
|
|
Before Width: | Height: | Size: 4.6 KiB |
@@ -1,85 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Generator: Adobe Illustrator 13.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 14948) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
version="1.0"
|
|
||||||
id="Foreground"
|
|
||||||
x="0px"
|
|
||||||
y="0px"
|
|
||||||
width="32"
|
|
||||||
height="32"
|
|
||||||
viewBox="0 0 32 32"
|
|
||||||
enable-background="new 0 0 16 16"
|
|
||||||
xml:space="preserve"
|
|
||||||
sodipodi:version="0.32"
|
|
||||||
inkscape:version="0.92.2 5c3e80d, 2017-08-06"
|
|
||||||
sodipodi:docname="close-window.svg"
|
|
||||||
inkscape:output_extension="org.inkscape.output.svg.inkscape"><metadata
|
|
||||||
id="metadata2399"><rdf:RDF><cc:Work
|
|
||||||
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
|
|
||||||
id="defs2397"><linearGradient
|
|
||||||
id="linearGradient3173"><stop
|
|
||||||
style="stop-color:#c4c4c4;stop-opacity:1;"
|
|
||||||
offset="0"
|
|
||||||
id="stop3175" /><stop
|
|
||||||
style="stop-color:#ffffff;stop-opacity:1;"
|
|
||||||
offset="1"
|
|
||||||
id="stop3177" /></linearGradient><inkscape:perspective
|
|
||||||
sodipodi:type="inkscape:persp3d"
|
|
||||||
inkscape:vp_x="0 : 11 : 1"
|
|
||||||
inkscape:vp_y="0 : 1375 : 0"
|
|
||||||
inkscape:vp_z="22 : 11 : 1"
|
|
||||||
inkscape:persp3d-origin="11 : 7.3333334 : 1"
|
|
||||||
id="perspective2401" /></defs><sodipodi:namedview
|
|
||||||
inkscape:window-height="1106"
|
|
||||||
inkscape:window-width="1700"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
guidetolerance="10.0"
|
|
||||||
gridtolerance="10.0"
|
|
||||||
objecttolerance="10.0"
|
|
||||||
borderopacity="1.0"
|
|
||||||
bordercolor="#666666"
|
|
||||||
pagecolor="#797979"
|
|
||||||
id="base"
|
|
||||||
showgrid="false"
|
|
||||||
inkscape:zoom="4"
|
|
||||||
inkscape:cx="28.483745"
|
|
||||||
inkscape:cy="67.714004"
|
|
||||||
inkscape:window-x="1427"
|
|
||||||
inkscape:window-y="127"
|
|
||||||
inkscape:current-layer="Foreground"
|
|
||||||
showguides="true"
|
|
||||||
inkscape:guide-bbox="true"
|
|
||||||
borderlayer="true"
|
|
||||||
inkscape:showpageshadow="false"
|
|
||||||
inkscape:window-maximized="0"
|
|
||||||
inkscape:document-rotation="0"><inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid11246"
|
|
||||||
empspacing="32"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" /></sodipodi:namedview><path
|
|
||||||
d="m 4.4362021,15.860384 c 0,-6.410121 5.1728276,-11.60728 11.5529359,-11.60728 6.380109,0 11.552937,5.197159 11.552937,11.60728 0,6.410122 -5.172828,11.607281 -11.552937,11.607281 -6.3801083,0 -11.5529359,-5.197159 -11.5529359,-11.607281 z"
|
|
||||||
id="path2394-32"
|
|
||||||
style="color:#000000;clip-rule:evenodd;display:inline;overflow:visible;visibility:visible;fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:#2975c4;stroke-width:4;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate"
|
|
||||||
sodipodi:nodetypes="csssc"
|
|
||||||
inkscape:connector-curvature="0" /><path
|
|
||||||
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.49900004;fill:#4a90d9;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.74932218;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate"
|
|
||||||
d="m 6.4654832,15.001321 c -0.025906,0.288419 -0.044417,0.579469 -0.044417,0.874662 0,5.313347 4.2883848,9.621271 9.5768588,9.621271 5.288466,0 9.575143,-4.307924 9.575143,-9.621271 0,-0.295193 -0.01852,-0.586243 -0.04441,-0.874662 -0.440376,4.903023 -4.536071,8.746611 -9.53073,8.746611 -4.994659,0 -9.0920617,-3.843588 -9.5324391,-8.746611 z"
|
|
||||||
id="path2561"
|
|
||||||
inkscape:connector-curvature="0" /><path
|
|
||||||
d="m 11.718386,11.639547 h 1.055207 c 0.01091,-1.26e-4 0.02193,-4.86e-4 0.03298,0 0.269026,0.01183 0.538019,0.135679 0.725455,0.329752 l 2.407192,2.407192 2.440166,-2.407192 c 0.28029,-0.243226 0.471333,-0.322366 0.725455,-0.329752 h 1.055207 v 1.055208 c 0,0.302285 -0.03623,0.581049 -0.263801,0.791405 l -2.407191,2.407191 2.374217,2.374216 c 0.198577,0.198559 0.296768,0.478484 0.296775,0.758432 v 1.055206 h -1.055211 c -0.279947,-10e-6 -0.559877,-0.09824 -0.75843,-0.296777 l -2.407192,-2.407192 -2.407192,2.407192 c -0.198551,0.198579 -0.478493,0.296777 -0.758429,0.296777 H 11.71839 v -1.055206 c -3e-6,-0.279936 0.0982,-0.559873 0.296777,-0.758432 L 14.422359,15.893351 12.015167,13.48616 C 11.79279,13.280784 11.69527,12.991003 11.71839,12.694755 Z"
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
id="path27279-0-5"
|
|
||||||
style="color:#bebebe;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:'Andale Mono';-inkscape-font-specification:'Andale Mono';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-anchor:start;display:inline;overflow:visible;visibility:visible;fill:#4a90d9;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.87958801;marker:none;enable-background:new"
|
|
||||||
sodipodi:nodetypes="ccsccccccccccccccccccccccc" /></svg>
|
|
Before Width: | Height: | Size: 5.3 KiB |
Before Width: | Height: | Size: 2.4 KiB |
Before Width: | Height: | Size: 2.3 KiB |
@@ -938,7 +938,6 @@ StScrollBar {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.pager-button {
|
.pager-button {
|
||||||
color: white;
|
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
width: 32px;
|
width: 32px;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
@@ -946,13 +945,8 @@ StScrollBar {
|
|||||||
&:active { background-color: transparentize($bg_color,0.95); }
|
&:active { background-color: transparentize($bg_color,0.95); }
|
||||||
}
|
}
|
||||||
|
|
||||||
.calendar-change-month-back { //arrow back
|
.calendar-change-month-back StIcon, .calendar-change-month-forward StIcon { // arrows
|
||||||
background-image: url("resource:///org/gnome/shell/theme/calendar-arrow-left.svg");
|
icon-size: 1.09em;
|
||||||
&:rtl { background-image: url("resource:///org/gnome/shell/theme/calendar-arrow-right.svg"); }
|
|
||||||
}
|
|
||||||
.calendar-change-month-forward { //arrow foreward
|
|
||||||
background-image: url("resource:///org/gnome/shell/theme/calendar-arrow-right.svg");
|
|
||||||
&:rtl { background-image: url("resource:///org/gnome/shell/theme/calendar-arrow-left.svg"); }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.calendar-day-base {
|
.calendar-day-base {
|
||||||
@@ -1142,17 +1136,16 @@ StScrollBar {
|
|||||||
& > StIcon { icon-size: 16px; }
|
& > StIcon { icon-size: 16px; }
|
||||||
}
|
}
|
||||||
|
|
||||||
//Activities Ripples
|
// Activities Ripples
|
||||||
.ripple-box {
|
.ripple-box {
|
||||||
width: 52px;
|
width: 52px;
|
||||||
height: 52px;
|
height: 52px;
|
||||||
background-image: url("resource:///org/gnome/shell/theme/corner-ripple-ltr.png");
|
border-radius: 0 0 52px 0; // radius the size of the box give us the curve
|
||||||
background-size: contain;
|
background-color: lighten(transparentize($selected_bg_color, 0.7), 40%);
|
||||||
|
box-shadow: 0 0 2px 2px lighten($selected_bg_color, 20%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.ripple-box:rtl {
|
.ripple-box:rtl { border-radius: 0 0 0 52px; } // just a simple change to the border radius position
|
||||||
background-image: url("resource:///org/gnome/shell/theme/corner-ripple-rtl.png");
|
|
||||||
}
|
|
||||||
|
|
||||||
// not really top bar only
|
// not really top bar only
|
||||||
.popup-menu-arrow { width: 16px; height: 16px; }
|
.popup-menu-arrow { width: 16px; height: 16px; }
|
||||||
@@ -1161,14 +1154,26 @@ StScrollBar {
|
|||||||
//close buttons
|
//close buttons
|
||||||
|
|
||||||
.window-close {
|
.window-close {
|
||||||
background-image: url("resource:///org/gnome/shell/theme/close-window.svg");
|
background-color: white;
|
||||||
background-size: 32px;
|
border-radius: 24px;
|
||||||
height: 32px;
|
border: 4px solid $selected_bg_color;
|
||||||
width: 32px;
|
box-shadow: inset 0 -4px 0 0 transparentize($selected_bg_color, 0.5);
|
||||||
-shell-close-overlap: 16px;
|
color: $selected_bg_color;
|
||||||
|
height: 24px;
|
||||||
|
width: 24px;
|
||||||
|
-shell-close-overlap: 14px;
|
||||||
|
|
||||||
&:hover { background-image: url("resource:///org/gnome/shell/theme/close-window-hover.svg"); }
|
&:hover {
|
||||||
&:active { background-image: url("resource:///org/gnome/shell/theme/close-window-active.svg"); }
|
background-color: $selected_bg_color;
|
||||||
|
border-color: white;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
background-color: mix(white, $selected_bg_color, 75%);
|
||||||
|
border-color: $selected_bg_color;
|
||||||
|
color: $selected_bg_color;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* NETWORK DIALOGS */
|
/* NETWORK DIALOGS */
|
||||||
@@ -1447,15 +1452,17 @@ StScrollBar {
|
|||||||
padding: 15px 20px;
|
padding: 15px 20px;
|
||||||
|
|
||||||
.page-indicator-icon {
|
.page-indicator-icon {
|
||||||
width: 18px;
|
width: 12px;
|
||||||
height: 18px;
|
height: 12px;
|
||||||
background-image: url(resource:///org/gnome/shell/theme/page-indicator-inactive.svg);
|
background-color: transparent;
|
||||||
|
border: 2px solid rgba(255, 255, 255, 0.4);
|
||||||
|
border-radius:12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover .page-indicator-icon { background-image: url(resource:///org/gnome/shell/theme/page-indicator-hover.svg); }
|
&:hover .page-indicator-icon { border-color: white; }
|
||||||
&:active .page-indicator-icon { background-image: url(resource:///org/gnome/shell/theme/page-indicator-active.svg); }
|
&:active .page-indicator-icon { border: none; margin: 2px; background-color:#fff; }
|
||||||
&:checked .page-indicator-icon,
|
&:checked .page-indicator-icon,
|
||||||
&:checked:active { background-image: url(resource:///org/gnome/shell/theme/page-indicator-checked.svg); }
|
&:checked:active { background-color: #fff;}
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-frequent-applications-label { @extend %status_text; }
|
.no-frequent-applications-label { @extend %status_text; }
|
||||||
|
@@ -1,71 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="18"
|
|
||||||
height="18"
|
|
||||||
id="svg4703"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48.4 r9939"
|
|
||||||
sodipodi:docname="page-indicator-pushed.svg">
|
|
||||||
<defs
|
|
||||||
id="defs4705" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0.0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="31.392433"
|
|
||||||
inkscape:cx="1.0245308"
|
|
||||||
inkscape:cy="13.3715"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="true"
|
|
||||||
inkscape:grid-bbox="true"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:window-width="2560"
|
|
||||||
inkscape:window-height="1374"
|
|
||||||
inkscape:window-x="0"
|
|
||||||
inkscape:window-y="27"
|
|
||||||
inkscape:window-maximized="1">
|
|
||||||
<inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid6140" />
|
|
||||||
</sodipodi:namedview>
|
|
||||||
<metadata
|
|
||||||
id="metadata4708">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
id="layer1"
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
transform="translate(0,2)">
|
|
||||||
<path
|
|
||||||
transform="matrix(0.54617904,0,0,0.62523128,-1131.9904,-392.39214)"
|
|
||||||
d="m 2099.9808,638.83099 a 10.985409,9.5964489 0 1 1 -21.9708,0 10.985409,9.5964489 0 1 1 21.9708,0 z"
|
|
||||||
sodipodi:ry="9.5964489"
|
|
||||||
sodipodi:rx="10.985409"
|
|
||||||
sodipodi:cy="638.83099"
|
|
||||||
sodipodi:cx="2088.9954"
|
|
||||||
id="path4711"
|
|
||||||
style="fill:#fdffff;fill-opacity:1;stroke:none"
|
|
||||||
sodipodi:type="arc" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.1 KiB |
@@ -1,67 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="18"
|
|
||||||
height="18"
|
|
||||||
id="svg4703"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48.4 r9939"
|
|
||||||
sodipodi:docname="page-indicator-active.svg">
|
|
||||||
<defs
|
|
||||||
id="defs4705" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0.0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="22.197802"
|
|
||||||
inkscape:cx="2.1522887"
|
|
||||||
inkscape:cy="16.782904"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="true"
|
|
||||||
inkscape:grid-bbox="true"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:window-width="1920"
|
|
||||||
inkscape:window-height="1021"
|
|
||||||
inkscape:window-x="0"
|
|
||||||
inkscape:window-y="27"
|
|
||||||
inkscape:window-maximized="1" />
|
|
||||||
<metadata
|
|
||||||
id="metadata4708">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title />
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
id="layer1"
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
transform="translate(0,2)">
|
|
||||||
<path
|
|
||||||
transform="matrix(0.72823872,0,0,0.8336417,-1512.2872,-525.55618)"
|
|
||||||
d="m 2099.9808,638.83099 c 0,5.29998 -4.9184,9.59645 -10.9854,9.59645 -6.0671,0 -10.9854,-4.29647 -10.9854,-9.59645 0,-5.29997 4.9183,-9.59645 10.9854,-9.59645 6.067,0 10.9854,4.29648 10.9854,9.59645 z"
|
|
||||||
sodipodi:ry="9.5964489"
|
|
||||||
sodipodi:rx="10.985409"
|
|
||||||
sodipodi:cy="638.83099"
|
|
||||||
sodipodi:cx="2088.9954"
|
|
||||||
id="path4711"
|
|
||||||
style="fill:#fdffff;fill-opacity:0.94117647;stroke:none"
|
|
||||||
sodipodi:type="arc" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.1 KiB |
@@ -1,67 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="18"
|
|
||||||
height="18"
|
|
||||||
id="svg5266"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48.4 r9939"
|
|
||||||
sodipodi:docname="page-indicator-inactive.svg">
|
|
||||||
<defs
|
|
||||||
id="defs5268" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="11.313709"
|
|
||||||
inkscape:cx="-2.307566"
|
|
||||||
inkscape:cy="17.859535"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="true"
|
|
||||||
inkscape:grid-bbox="true"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:window-width="2560"
|
|
||||||
inkscape:window-height="1374"
|
|
||||||
inkscape:window-x="0"
|
|
||||||
inkscape:window-y="27"
|
|
||||||
inkscape:window-maximized="1" />
|
|
||||||
<metadata
|
|
||||||
id="metadata5271">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
id="layer1"
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
transform="translate(0,2)">
|
|
||||||
<path
|
|
||||||
sodipodi:type="arc"
|
|
||||||
style="fill:none;fill-opacity:0;stroke:#ffffff;stroke-width:2.93356276000000005;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
|
|
||||||
id="path5274"
|
|
||||||
sodipodi:cx="2088.9954"
|
|
||||||
sodipodi:cy="638.83099"
|
|
||||||
sodipodi:rx="10.985409"
|
|
||||||
sodipodi:ry="9.5964489"
|
|
||||||
d="m 2099.9808,638.83099 c 0,5.29998 -4.9184,9.59645 -10.9854,9.59645 -6.0671,0 -10.9854,-4.29647 -10.9854,-9.59645 0,-5.29997 4.9183,-9.59645 10.9854,-9.59645 6.067,0 10.9854,4.29648 10.9854,9.59645 z"
|
|
||||||
transform="matrix(0.63720887,0,0,0.72943648,-1322.1264,-458.98661)" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.2 KiB |
@@ -1,67 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
width="18"
|
|
||||||
height="18"
|
|
||||||
id="svg5266"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48.4 r9939"
|
|
||||||
sodipodi:docname="page-indicator-inactive.svg">
|
|
||||||
<defs
|
|
||||||
id="defs5268" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
id="base"
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1.0"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:zoom="11.313709"
|
|
||||||
inkscape:cx="-2.307566"
|
|
||||||
inkscape:cy="17.859535"
|
|
||||||
inkscape:current-layer="layer1"
|
|
||||||
showgrid="true"
|
|
||||||
inkscape:grid-bbox="true"
|
|
||||||
inkscape:document-units="px"
|
|
||||||
inkscape:window-width="2560"
|
|
||||||
inkscape:window-height="1374"
|
|
||||||
inkscape:window-x="0"
|
|
||||||
inkscape:window-y="27"
|
|
||||||
inkscape:window-maximized="1" />
|
|
||||||
<metadata
|
|
||||||
id="metadata5271">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title />
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<g
|
|
||||||
id="layer1"
|
|
||||||
inkscape:label="Layer 1"
|
|
||||||
inkscape:groupmode="layer"
|
|
||||||
transform="translate(0,2)">
|
|
||||||
<path
|
|
||||||
sodipodi:type="arc"
|
|
||||||
style="fill:none;fill-opacity:0;stroke:#ffffff;stroke-width:2.93356276000000005;stroke-miterlimit:4;stroke-opacity:0.39215686000000000;stroke-dasharray:none"
|
|
||||||
id="path5274"
|
|
||||||
sodipodi:cx="2088.9954"
|
|
||||||
sodipodi:cy="638.83099"
|
|
||||||
sodipodi:rx="10.985409"
|
|
||||||
sodipodi:ry="9.5964489"
|
|
||||||
d="m 2099.9808,638.83099 c 0,5.29998 -4.9184,9.59645 -10.9854,9.59645 -6.0671,0 -10.9854,-4.29647 -10.9854,-9.59645 0,-5.29997 4.9183,-9.59645 10.9854,-9.59645 6.067,0 10.9854,4.29648 10.9854,9.59645 z"
|
|
||||||
transform="matrix(0.63720887,0,0,0.72943648,-1322.1264,-458.98661)" />
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.2 KiB |
@@ -25,7 +25,7 @@ its dependencies to build from tarballs.</description>
|
|||||||
<homepage rdf:resource="https://wiki.gnome.org/Projects/GnomeShell" />
|
<homepage rdf:resource="https://wiki.gnome.org/Projects/GnomeShell" />
|
||||||
<mailing-list rdf:resource="http://mail.gnome.org/mailman/listinfo/gnome-shell-list" />
|
<mailing-list rdf:resource="http://mail.gnome.org/mailman/listinfo/gnome-shell-list" />
|
||||||
<download-page rdf:resource="http://download.gnome.org/sources/gnome-shell/" />
|
<download-page rdf:resource="http://download.gnome.org/sources/gnome-shell/" />
|
||||||
<bug-database rdf:resource="https://bugzilla.gnome.org/browse.cgi?product=gnome-shell" />
|
<bug-database rdf:resource="https://gitlab.gnome.org/GNOME/gnome-shell/issues/" />
|
||||||
|
|
||||||
<category rdf:resource="http://api.gnome.org/doap-extensions#core" />
|
<category rdf:resource="http://api.gnome.org/doap-extensions#core" />
|
||||||
<programming-language>JavaScript</programming-language>
|
<programming-language>JavaScript</programming-language>
|
||||||
|
@@ -210,7 +210,7 @@ var IBusManager = new Lang.Class({
|
|||||||
}
|
}
|
||||||
|
|
||||||
this._ibus.set_global_engine_async(id, this._MAX_INPUT_SOURCE_ACTIVATION_TIME,
|
this._ibus.set_global_engine_async(id, this._MAX_INPUT_SOURCE_ACTIVATION_TIME,
|
||||||
null, callback);
|
null, callback || null);
|
||||||
},
|
},
|
||||||
|
|
||||||
preloadEngines(ids) {
|
preloadEngines(ids) {
|
||||||
|
@@ -17,6 +17,7 @@ var InputMethod = new Lang.Class({
|
|||||||
this._currentFocus = null;
|
this._currentFocus = null;
|
||||||
this._preeditStr = '';
|
this._preeditStr = '';
|
||||||
this._preeditPos = 0;
|
this._preeditPos = 0;
|
||||||
|
this._preeditVisible = false;
|
||||||
this._ibus = IBus.Bus.new_async();
|
this._ibus = IBus.Bus.new_async();
|
||||||
this._ibus.connect('connected', this._onConnected.bind(this));
|
this._ibus.connect('connected', this._onConnected.bind(this));
|
||||||
this._ibus.connect('disconnected', this._clear.bind(this));
|
this._ibus.connect('disconnected', this._clear.bind(this));
|
||||||
@@ -80,6 +81,7 @@ var InputMethod = new Lang.Class({
|
|||||||
this._enabled = false;
|
this._enabled = false;
|
||||||
this._preeditStr = ''
|
this._preeditStr = ''
|
||||||
this._preeditPos = 0;
|
this._preeditPos = 0;
|
||||||
|
this._preeditVisible = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
_emitRequestSurrounding() {
|
_emitRequestSurrounding() {
|
||||||
@@ -98,20 +100,27 @@ var InputMethod = new Lang.Class({
|
|||||||
_onUpdatePreeditText(context, text, pos, visible) {
|
_onUpdatePreeditText(context, text, pos, visible) {
|
||||||
if (text == null)
|
if (text == null)
|
||||||
return;
|
return;
|
||||||
this._preeditStr = text.get_text();
|
|
||||||
this._preeditPos = pos;
|
let preedit = text.get_text();
|
||||||
|
|
||||||
if (visible)
|
if (visible)
|
||||||
this.set_preedit_text(this._preeditStr, pos);
|
this.set_preedit_text(preedit, pos);
|
||||||
else
|
else if (this._preeditVisible)
|
||||||
this.set_preedit_text(null, pos);
|
this.set_preedit_text(null, pos);
|
||||||
|
|
||||||
|
this._preeditStr = preedit;
|
||||||
|
this._preeditPos = pos;
|
||||||
|
this._preeditVisible = visible;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onShowPreeditText(context) {
|
_onShowPreeditText(context) {
|
||||||
|
this._preeditVisible = true;
|
||||||
this.set_preedit_text(this._preeditStr, this._preeditPos);
|
this.set_preedit_text(this._preeditStr, this._preeditPos);
|
||||||
},
|
},
|
||||||
|
|
||||||
_onHidePreeditText(context) {
|
_onHidePreeditText(context) {
|
||||||
this.set_preedit_text(null, this._preeditPos);
|
this.set_preedit_text(null, this._preeditPos);
|
||||||
|
this._preeditVisible = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onForwardKeyEvent(context, keyval, keycode, state) {
|
_onForwardKeyEvent(context, keyval, keycode, state) {
|
||||||
@@ -144,8 +153,11 @@ var InputMethod = new Lang.Class({
|
|||||||
this._updateCapabilities();
|
this._updateCapabilities();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Unset any preedit text
|
if (this._preeditStr) {
|
||||||
this.set_preedit_text(null, 0);
|
// Unset any preedit text
|
||||||
|
this.set_preedit_text(null, 0);
|
||||||
|
this._preeditStr = null;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_reset() {
|
vfunc_reset() {
|
||||||
@@ -154,8 +166,11 @@ var InputMethod = new Lang.Class({
|
|||||||
this._emitRequestSurrounding();
|
this._emitRequestSurrounding();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Unset any preedit text
|
if (this._preeditStr) {
|
||||||
this.set_preedit_text(null, 0);
|
// Unset any preedit text
|
||||||
|
this.set_preedit_text(null, 0);
|
||||||
|
this._preeditStr = null;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_set_cursor_location(rect) {
|
vfunc_set_cursor_location(rect) {
|
||||||
|
@@ -809,11 +809,11 @@ var FrequentView = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
hasUsefulData() {
|
hasUsefulData() {
|
||||||
return this._usage.get_most_used("").length >= MIN_FREQUENT_APPS_COUNT;
|
return this._usage.get_most_used().length >= MIN_FREQUENT_APPS_COUNT;
|
||||||
},
|
},
|
||||||
|
|
||||||
_loadApps() {
|
_loadApps() {
|
||||||
let mostUsed = this._usage.get_most_used ("");
|
let mostUsed = this._usage.get_most_used();
|
||||||
let hasUsefulData = this.hasUsefulData();
|
let hasUsefulData = this.hasUsefulData();
|
||||||
this._noFrequentAppsLabel.visible = !hasUsefulData;
|
this._noFrequentAppsLabel.visible = !hasUsefulData;
|
||||||
if(!hasUsefulData)
|
if(!hasUsefulData)
|
||||||
@@ -1112,7 +1112,7 @@ var AppSearchProvider = new Lang.Class({
|
|||||||
return app && app.should_show();
|
return app && app.should_show();
|
||||||
});
|
});
|
||||||
results = results.concat(group.sort(
|
results = results.concat(group.sort(
|
||||||
(a, b) => usage.compare('', a, b)
|
(a, b) => usage.compare(a, b)
|
||||||
));
|
));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@@ -446,6 +446,7 @@ var Calendar = new Lang.Class({
|
|||||||
this._backButton = new St.Button({ style_class: 'calendar-change-month-back pager-button',
|
this._backButton = new St.Button({ style_class: 'calendar-change-month-back pager-button',
|
||||||
accessible_name: _("Previous month"),
|
accessible_name: _("Previous month"),
|
||||||
can_focus: true });
|
can_focus: true });
|
||||||
|
this._backButton.add_actor(new St.Icon({ icon_name: 'pan-start-symbolic' }));
|
||||||
this._topBox.add(this._backButton);
|
this._topBox.add(this._backButton);
|
||||||
this._backButton.connect('clicked', this._onPrevMonthButtonClicked.bind(this));
|
this._backButton.connect('clicked', this._onPrevMonthButtonClicked.bind(this));
|
||||||
|
|
||||||
@@ -456,6 +457,7 @@ var Calendar = new Lang.Class({
|
|||||||
this._forwardButton = new St.Button({ style_class: 'calendar-change-month-forward pager-button',
|
this._forwardButton = new St.Button({ style_class: 'calendar-change-month-forward pager-button',
|
||||||
accessible_name: _("Next month"),
|
accessible_name: _("Next month"),
|
||||||
can_focus: true });
|
can_focus: true });
|
||||||
|
this._forwardButton.add_actor(new St.Icon({ icon_name: 'pan-end-symbolic' }));
|
||||||
this._topBox.add(this._forwardButton);
|
this._topBox.add(this._forwardButton);
|
||||||
this._forwardButton.connect('clicked', this._onNextMonthButtonClicked.bind(this));
|
this._forwardButton.connect('clicked', this._onNextMonthButtonClicked.bind(this));
|
||||||
|
|
||||||
|
@@ -55,6 +55,8 @@ var DashItemContainer = new Lang.Class({
|
|||||||
this.animatingOut = false;
|
this.animatingOut = false;
|
||||||
|
|
||||||
this.connect('destroy', () => {
|
this.connect('destroy', () => {
|
||||||
|
if (this.child != null)
|
||||||
|
this.child.destroy();
|
||||||
this.label.destroy();
|
this.label.destroy();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@@ -344,10 +344,10 @@ var IconGrid = new Lang.Class({
|
|||||||
|
|
||||||
if (this._rowLimit && rowIndex >= this._rowLimit ||
|
if (this._rowLimit && rowIndex >= this._rowLimit ||
|
||||||
this._fillParent && childBox.y2 > availHeight - this.bottomPadding) {
|
this._fillParent && childBox.y2 > availHeight - this.bottomPadding) {
|
||||||
children[i]._skipPaint = true;
|
children[i].hide();
|
||||||
} else {
|
} else {
|
||||||
children[i].allocate(childBox, flags);
|
children[i].allocate(childBox, flags);
|
||||||
children[i]._skipPaint = false;
|
children[i].show();
|
||||||
}
|
}
|
||||||
|
|
||||||
columnIndex++;
|
columnIndex++;
|
||||||
@@ -365,24 +365,6 @@ var IconGrid = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_paint() {
|
|
||||||
this.paint_background();
|
|
||||||
|
|
||||||
this.get_children().forEach(c => {
|
|
||||||
if (!c._skipPaint)
|
|
||||||
c.paint();
|
|
||||||
});
|
|
||||||
},
|
|
||||||
|
|
||||||
vfunc_pick(color) {
|
|
||||||
this.parent(color);
|
|
||||||
|
|
||||||
this.get_children().forEach(c => {
|
|
||||||
if (!c._skipPaint)
|
|
||||||
c.paint();
|
|
||||||
});
|
|
||||||
},
|
|
||||||
|
|
||||||
vfunc_get_paint_volume(paintVolume) {
|
vfunc_get_paint_volume(paintVolume) {
|
||||||
// Setting the paint volume does not make sense when we don't have
|
// Setting the paint volume does not make sense when we don't have
|
||||||
// any allocation
|
// any allocation
|
||||||
@@ -412,9 +394,6 @@ var IconGrid = new Lang.Class({
|
|||||||
if (!child.visible)
|
if (!child.visible)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (child._skipPaint)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
let childVolume = child.get_transformed_paint_volume(this);
|
let childVolume = child.get_transformed_paint_volume(this);
|
||||||
if (!childVolume)
|
if (!childVolume)
|
||||||
return false
|
return false
|
||||||
@@ -714,7 +693,7 @@ var IconGrid = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
visibleItemsCount() {
|
visibleItemsCount() {
|
||||||
return this.get_children().filter(c => !c._skipPaint).length;
|
return this.get_children().filter(c => c.is_visible()).length;
|
||||||
},
|
},
|
||||||
|
|
||||||
setSpacing(spacing) {
|
setSpacing(spacing) {
|
||||||
@@ -859,7 +838,7 @@ var PaginatedIconGrid = new Lang.Class({
|
|||||||
for (let i = 0; i < children.length; i++) {
|
for (let i = 0; i < children.length; i++) {
|
||||||
let childBox = this._calculateChildBox(children[i], x, y, box);
|
let childBox = this._calculateChildBox(children[i], x, y, box);
|
||||||
children[i].allocate(childBox, flags);
|
children[i].allocate(childBox, flags);
|
||||||
children[i]._skipPaint = false;
|
children[i].show();
|
||||||
|
|
||||||
columnIndex++;
|
columnIndex++;
|
||||||
if (columnIndex == nColumns) {
|
if (columnIndex == nColumns) {
|
||||||
|
@@ -1298,10 +1298,8 @@ var MessageTray = new Lang.Class({
|
|||||||
}
|
}
|
||||||
|
|
||||||
this._banner = this._notification.createBanner();
|
this._banner = this._notification.createBanner();
|
||||||
this._bannerClickedId = this._banner.connect('done-displaying', () => {
|
this._bannerClickedId = this._banner.connect('done-displaying',
|
||||||
Meta.enable_unredirect_for_display(global.display);
|
this._escapeTray.bind(this));
|
||||||
this._escapeTray();
|
|
||||||
});
|
|
||||||
this._bannerUnfocusedId = this._banner.connect('unfocused', () => {
|
this._bannerUnfocusedId = this._banner.connect('unfocused', () => {
|
||||||
this._updateState();
|
this._updateState();
|
||||||
});
|
});
|
||||||
@@ -1451,6 +1449,7 @@ var MessageTray = new Lang.Class({
|
|||||||
|
|
||||||
this._pointerInNotification = false;
|
this._pointerInNotification = false;
|
||||||
this._notificationRemoved = false;
|
this._notificationRemoved = false;
|
||||||
|
Meta.enable_unredirect_for_display(global.display);
|
||||||
|
|
||||||
this._banner.actor.destroy();
|
this._banner.actor.destroy();
|
||||||
this._banner = null;
|
this._banner = null;
|
||||||
|
@@ -77,10 +77,8 @@ var FdoNotificationDaemon = new Lang.Class({
|
|||||||
bitsPerSample, nChannels, data] = hints['image-data'];
|
bitsPerSample, nChannels, data] = hints['image-data'];
|
||||||
return Shell.util_create_pixbuf_from_data(data, GdkPixbuf.Colorspace.RGB, hasAlpha,
|
return Shell.util_create_pixbuf_from_data(data, GdkPixbuf.Colorspace.RGB, hasAlpha,
|
||||||
bitsPerSample, width, height, rowStride);
|
bitsPerSample, width, height, rowStride);
|
||||||
} else if (hints['image-path']) {
|
|
||||||
return new Gio.FileIcon({ file: Gio.File.new_for_path(hints['image-path']) });
|
|
||||||
}
|
}
|
||||||
return null;
|
return this._iconForNotificationData(hints['image-path']);
|
||||||
},
|
},
|
||||||
|
|
||||||
_fallbackIconForNotificationData(hints) {
|
_fallbackIconForNotificationData(hints) {
|
||||||
@@ -294,7 +292,7 @@ var FdoNotificationDaemon = new Lang.Class({
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
let gicon = this._iconForNotificationData(icon, hints);
|
let gicon = this._iconForNotificationData(icon);
|
||||||
let gimage = this._imageForNotificationData(hints);
|
let gimage = this._imageForNotificationData(hints);
|
||||||
|
|
||||||
// If an icon is not specified, we use 'image-data' or 'image-path' hint for an icon
|
// If an icon is not specified, we use 'image-data' or 'image-path' hint for an icon
|
||||||
|
@@ -101,9 +101,20 @@ var GnomeShell = new Lang.Class({
|
|||||||
Main.osdWindowManager.show(monitorIndex, icon, label, level, maxLevel);
|
Main.osdWindowManager.show(monitorIndex, icon, label, level, maxLevel);
|
||||||
},
|
},
|
||||||
|
|
||||||
FocusApp(id) {
|
FocusAppAsync(params, invocation) {
|
||||||
|
let [id] = params;
|
||||||
|
let appSys = Shell.AppSystem.get_default();
|
||||||
|
if (appSys.lookup_app(id) == null) {
|
||||||
|
invocation.return_error_literal(
|
||||||
|
Gio.DBusError,
|
||||||
|
Gio.DBusError.FILE_NOT_FOUND,
|
||||||
|
`No application with ID ${id}`);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
this.ShowApplications();
|
this.ShowApplications();
|
||||||
Main.overview.viewSelector.appDisplay.selectApp(id);
|
Main.overview.viewSelector.appDisplay.selectApp(id);
|
||||||
|
invocation.return_value(null);
|
||||||
},
|
},
|
||||||
|
|
||||||
ShowApplications() {
|
ShowApplications() {
|
||||||
|
@@ -70,7 +70,9 @@ var Indicator = new Lang.Class({
|
|||||||
seconds = this._proxy.TimeToFull;
|
seconds = this._proxy.TimeToFull;
|
||||||
else if (this._proxy.State == UPower.DeviceState.DISCHARGING)
|
else if (this._proxy.State == UPower.DeviceState.DISCHARGING)
|
||||||
seconds = this._proxy.TimeToEmpty;
|
seconds = this._proxy.TimeToEmpty;
|
||||||
// state is one of PENDING_CHARGING, PENDING_DISCHARGING
|
else if (this._proxy.State == UPower.DeviceState.PENDING_CHARGE)
|
||||||
|
return _("Not Charging");
|
||||||
|
// state is PENDING_DISCHARGE
|
||||||
else
|
else
|
||||||
return _("Estimating…");
|
return _("Estimating…");
|
||||||
|
|
||||||
|
@@ -58,6 +58,9 @@ var AltSwitcher = new Lang.Class({
|
|||||||
childToShow = this._standard;
|
childToShow = this._standard;
|
||||||
} else if (this._alternate.visible) {
|
} else if (this._alternate.visible) {
|
||||||
childToShow = this._alternate;
|
childToShow = this._alternate;
|
||||||
|
} else {
|
||||||
|
this.actor.hide();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
let childShown = this.actor.get_child();
|
let childShown = this.actor.get_child();
|
||||||
@@ -79,7 +82,7 @@ var AltSwitcher = new Lang.Class({
|
|||||||
global.sync_pointer();
|
global.sync_pointer();
|
||||||
}
|
}
|
||||||
|
|
||||||
this.actor.visible = (childToShow != null);
|
this.actor.show();
|
||||||
},
|
},
|
||||||
|
|
||||||
_onDestroy() {
|
_onDestroy() {
|
||||||
|
@@ -195,7 +195,7 @@ var AuthRobot = new Lang.Class({
|
|||||||
if (this._enrolling)
|
if (this._enrolling)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this.enrolling = true;
|
this._enrolling = true;
|
||||||
GLib.idle_add(GLib.PRIORITY_DEFAULT,
|
GLib.idle_add(GLib.PRIORITY_DEFAULT,
|
||||||
this._enrollDevicesIdle.bind(this));
|
this._enrollDevicesIdle.bind(this));
|
||||||
},
|
},
|
||||||
|
@@ -13,6 +13,8 @@ var WindowAttentionHandler = new Lang.Class({
|
|||||||
this._tracker = Shell.WindowTracker.get_default();
|
this._tracker = Shell.WindowTracker.get_default();
|
||||||
this._windowDemandsAttentionId = global.display.connect('window-demands-attention',
|
this._windowDemandsAttentionId = global.display.connect('window-demands-attention',
|
||||||
this._onWindowDemandsAttention.bind(this));
|
this._onWindowDemandsAttention.bind(this));
|
||||||
|
this._windowMarkedUrgentId = global.display.connect('window-marked-urgent',
|
||||||
|
this._onWindowDemandsAttention.bind(this));
|
||||||
},
|
},
|
||||||
|
|
||||||
_getTitleAndBanner(app, window) {
|
_getTitleAndBanner(app, window) {
|
||||||
@@ -66,7 +68,9 @@ var Source = new Lang.Class({
|
|||||||
|
|
||||||
this.signalIDs = [];
|
this.signalIDs = [];
|
||||||
this.signalIDs.push(this._window.connect('notify::demands-attention',
|
this.signalIDs.push(this._window.connect('notify::demands-attention',
|
||||||
() => { this.destroy(); }));
|
this._sync.bind(this)));
|
||||||
|
this.signalIDs.push(this._window.connect('notify::urgent',
|
||||||
|
this._sync.bind(this)));
|
||||||
this.signalIDs.push(this._window.connect('focus',
|
this.signalIDs.push(this._window.connect('focus',
|
||||||
() => { this.destroy(); }));
|
() => { this.destroy(); }));
|
||||||
this.signalIDs.push(this._window.connect('unmanaged',
|
this.signalIDs.push(this._window.connect('unmanaged',
|
||||||
@@ -75,6 +79,12 @@ var Source = new Lang.Class({
|
|||||||
this.connect('destroy', this._onDestroy.bind(this));
|
this.connect('destroy', this._onDestroy.bind(this));
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_sync() {
|
||||||
|
if (this._window.demands_attention || this._window.urgent)
|
||||||
|
return;
|
||||||
|
this.destroy();
|
||||||
|
},
|
||||||
|
|
||||||
_onDestroy() {
|
_onDestroy() {
|
||||||
for(let i = 0; i < this.signalIDs.length; i++) {
|
for(let i = 0; i < this.signalIDs.length; i++) {
|
||||||
this._window.disconnect(this.signalIDs[i]);
|
this._window.disconnect(this.signalIDs[i]);
|
||||||
|
@@ -478,6 +478,7 @@ var TouchpadWorkspaceSwitchAction = new Lang.Class({
|
|||||||
this._dx = 0;
|
this._dx = 0;
|
||||||
this._dy = 0;
|
this._dy = 0;
|
||||||
actor.connect('captured-event', this._handleEvent.bind(this));
|
actor.connect('captured-event', this._handleEvent.bind(this));
|
||||||
|
this._touchpadSettings = new Gio.Settings({schema_id: 'org.gnome.desktop.peripherals.touchpad'});
|
||||||
},
|
},
|
||||||
|
|
||||||
_checkActivated() {
|
_checkActivated() {
|
||||||
@@ -515,7 +516,11 @@ var TouchpadWorkspaceSwitchAction = new Lang.Class({
|
|||||||
|
|
||||||
// Scale deltas up a bit to make it feel snappier
|
// Scale deltas up a bit to make it feel snappier
|
||||||
this._dx += dx * 2;
|
this._dx += dx * 2;
|
||||||
this._dy += dy * 2;
|
if(!(this._touchpadSettings.get_boolean('natural-scroll')))
|
||||||
|
this._dy -= dy * 2;
|
||||||
|
else
|
||||||
|
this._dy += dy * 2;
|
||||||
|
|
||||||
this.emit('motion', this._dx, this._dy);
|
this.emit('motion', this._dx, this._dy);
|
||||||
} else {
|
} else {
|
||||||
if ((event.get_gesture_phase() == Clutter.TouchpadGesturePhase.END && ! this._checkActivated()) ||
|
if ((event.get_gesture_phase() == Clutter.TouchpadGesturePhase.END && ! this._checkActivated()) ||
|
||||||
|
@@ -465,13 +465,15 @@ var WindowOverlay = new Lang.Class({
|
|||||||
title.clutter_text.ellipsize = Pango.EllipsizeMode.END;
|
title.clutter_text.ellipsize = Pango.EllipsizeMode.END;
|
||||||
windowClone.actor.label_actor = title;
|
windowClone.actor.label_actor = title;
|
||||||
|
|
||||||
|
this._maxTitleWidth = -1;
|
||||||
|
|
||||||
this._updateCaptionId = metaWindow.connect('notify::title', w => {
|
this._updateCaptionId = metaWindow.connect('notify::title', w => {
|
||||||
this.title.text = w.title;
|
|
||||||
this.title.text = this._getCaption();
|
this.title.text = this._getCaption();
|
||||||
this.relayout(false);
|
this.relayout(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
let button = new St.Button({ style_class: 'window-close' });
|
let button = new St.Button({ style_class: 'window-close' });
|
||||||
|
button.add_actor(new St.Icon({ icon_name: 'window-close-symbolic' }));
|
||||||
button._overlap = 0;
|
button._overlap = 0;
|
||||||
|
|
||||||
this._idleToggleCloseId = 0;
|
this._idleToggleCloseId = 0;
|
||||||
@@ -528,6 +530,13 @@ var WindowOverlay = new Lang.Class({
|
|||||||
Math.max(this.borderSize, this.closeButton.width - this.closeButton._overlap)];
|
Math.max(this.borderSize, this.closeButton.width - this.closeButton._overlap)];
|
||||||
},
|
},
|
||||||
|
|
||||||
|
setMaxChromeWidth(max) {
|
||||||
|
if (this._maxTitleWidth == max)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this._maxTitleWidth = max;
|
||||||
|
},
|
||||||
|
|
||||||
relayout(animate) {
|
relayout(animate) {
|
||||||
let button = this.closeButton;
|
let button = this.closeButton;
|
||||||
let title = this.title;
|
let title = this.title;
|
||||||
@@ -554,13 +563,26 @@ var WindowOverlay = new Lang.Class({
|
|||||||
else
|
else
|
||||||
button.set_position(Math.floor(buttonX), Math.floor(buttonY));
|
button.set_position(Math.floor(buttonX), Math.floor(buttonY));
|
||||||
|
|
||||||
let titleX = cloneX + (cloneWidth - title.width) / 2;
|
// Clutter.Actor.get_preferred_width() will return the fixed width if
|
||||||
|
// one is set, so we need to reset the width by calling set_width(-1),
|
||||||
|
// to forward the call down to StLabel.
|
||||||
|
// We also need to save and restore the current width, otherwise the
|
||||||
|
// animation starts from the wrong point.
|
||||||
|
let prevTitleWidth = title.width;
|
||||||
|
title.set_width(-1);
|
||||||
|
|
||||||
|
let [titleMinWidth, titleNatWidth] = title.get_preferred_width(-1);
|
||||||
|
let titleWidth = Math.max(titleMinWidth,
|
||||||
|
Math.min(titleNatWidth, this._maxTitleWidth));
|
||||||
|
title.width = prevTitleWidth;
|
||||||
|
|
||||||
|
let titleX = cloneX + (cloneWidth - titleWidth) / 2;
|
||||||
let titleY = cloneY + cloneHeight - (title.height - this.borderSize) / 2;
|
let titleY = cloneY + cloneHeight - (title.height - this.borderSize) / 2;
|
||||||
|
|
||||||
if (animate) {
|
if (animate) {
|
||||||
this._animateOverlayActor(title, Math.floor(titleX), Math.floor(titleY), title.width);
|
this._animateOverlayActor(title, Math.floor(titleX), Math.floor(titleY), titleWidth);
|
||||||
} else {
|
} else {
|
||||||
title.width = title.width;
|
title.width = titleWidth;
|
||||||
title.set_position(Math.floor(titleX), Math.floor(titleY));
|
title.set_position(Math.floor(titleX), Math.floor(titleY));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1306,6 +1328,12 @@ var Workspace = new Lang.Class({
|
|||||||
let cloneHeight = clone.actor.height * scale;
|
let cloneHeight = clone.actor.height * scale;
|
||||||
clone.slot = [x, y, cloneWidth, cloneHeight];
|
clone.slot = [x, y, cloneWidth, cloneHeight];
|
||||||
|
|
||||||
|
let cloneCenter = x + cloneWidth / 2;
|
||||||
|
let maxChromeWidth = 2 * Math.min(
|
||||||
|
cloneCenter - area.x,
|
||||||
|
area.x + area.width - cloneCenter);
|
||||||
|
overlay.setMaxChromeWidth(Math.round(maxChromeWidth));
|
||||||
|
|
||||||
if (overlay && (initialPositioning || !clone.positioned))
|
if (overlay && (initialPositioning || !clone.positioned))
|
||||||
overlay.hide();
|
overlay.hide();
|
||||||
|
|
||||||
|
15
meson.build
@@ -1,12 +1,12 @@
|
|||||||
project('gnome-shell', 'c',
|
project('gnome-shell', 'c',
|
||||||
version: '3.30.1',
|
version: '3.31.2',
|
||||||
meson_version: '>= 0.47.0',
|
meson_version: '>= 0.47.0',
|
||||||
license: 'GPLv2+'
|
license: 'GPLv2+'
|
||||||
)
|
)
|
||||||
|
|
||||||
# We depend on a specific version of the libmutter API. The mutter variants of
|
# We depend on a specific version of the libmutter API. The mutter variants of
|
||||||
# the Cogl and Clutter libraries also use this API version.
|
# the Cogl and Clutter libraries also use this API version.
|
||||||
mutter_api_version = '3'
|
mutter_api_version = '4'
|
||||||
|
|
||||||
clutter_pc = 'mutter-clutter-' + mutter_api_version
|
clutter_pc = 'mutter-clutter-' + mutter_api_version
|
||||||
cogl_pc = 'mutter-cogl-' + mutter_api_version
|
cogl_pc = 'mutter-cogl-' + mutter_api_version
|
||||||
@@ -23,7 +23,7 @@ gi_req = '>= 1.49.1'
|
|||||||
gjs_req = '>= 1.47.0'
|
gjs_req = '>= 1.47.0'
|
||||||
gtk_req = '>= 3.15.0'
|
gtk_req = '>= 3.15.0'
|
||||||
json_glib_req = '>= 0.13.2'
|
json_glib_req = '>= 0.13.2'
|
||||||
mutter_req = '>= 3.30.1'
|
mutter_req = '>= 3.31.2'
|
||||||
polkit_req = '>= 0.100'
|
polkit_req = '>= 0.100'
|
||||||
schemas_req = '>= 3.27.90'
|
schemas_req = '>= 3.27.90'
|
||||||
startup_req = '>= 0.11'
|
startup_req = '>= 0.11'
|
||||||
@@ -54,13 +54,10 @@ convertdir = join_paths(datadir, 'GConf', 'gsettings')
|
|||||||
desktopdir = join_paths(datadir, 'applications')
|
desktopdir = join_paths(datadir, 'applications')
|
||||||
ifacedir = join_paths(datadir, 'dbus-1', 'interfaces')
|
ifacedir = join_paths(datadir, 'dbus-1', 'interfaces')
|
||||||
localedir = join_paths(datadir, 'locale')
|
localedir = join_paths(datadir, 'locale')
|
||||||
mozplugindir = join_paths(libdir, 'mozilla', 'plugins')
|
|
||||||
portaldir = join_paths(datadir, 'xdg-desktop-portal', 'portals')
|
portaldir = join_paths(datadir, 'xdg-desktop-portal', 'portals')
|
||||||
schemadir = join_paths(datadir, 'glib-2.0', 'schemas')
|
schemadir = join_paths(datadir, 'glib-2.0', 'schemas')
|
||||||
servicedir = join_paths(datadir, 'dbus-1', 'services')
|
servicedir = join_paths(datadir, 'dbus-1', 'services')
|
||||||
|
|
||||||
plugindir = get_variable('BROWSER_PLUGIN_DIR', mozplugindir)
|
|
||||||
|
|
||||||
# XXX: Once https://github.com/systemd/systemd/issues/9595 is fixed and we can
|
# XXX: Once https://github.com/systemd/systemd/issues/9595 is fixed and we can
|
||||||
# depend on this version, replace with something like:
|
# depend on this version, replace with something like:
|
||||||
# systemduserunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
|
# systemduserunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
|
||||||
@@ -134,12 +131,6 @@ else
|
|||||||
have_systemd = false
|
have_systemd = false
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if get_option('browser_plugin')
|
|
||||||
json_glib_dep = dependency('json-glib-1.0', version: json_glib_req)
|
|
||||||
|
|
||||||
subdir('browser-plugin')
|
|
||||||
endif
|
|
||||||
|
|
||||||
if get_option('man')
|
if get_option('man')
|
||||||
xsltproc = find_program('xsltproc')
|
xsltproc = find_program('xsltproc')
|
||||||
|
|
||||||
|
@@ -1,9 +1,3 @@
|
|||||||
option('browser_plugin',
|
|
||||||
type: 'boolean',
|
|
||||||
value: true,
|
|
||||||
description: 'Enable extensions.gnome.org browser plugin'
|
|
||||||
)
|
|
||||||
|
|
||||||
option('gtk_doc',
|
option('gtk_doc',
|
||||||
type: 'boolean',
|
type: 'boolean',
|
||||||
value: false,
|
value: false,
|
||||||
|
52
po/eo.po
@@ -6,20 +6,22 @@
|
|||||||
# Daniel PUENTES <blatberk@openmailbox.org>, 2015.
|
# Daniel PUENTES <blatberk@openmailbox.org>, 2015.
|
||||||
# Nicolas MAIA < >, 2015.
|
# Nicolas MAIA < >, 2015.
|
||||||
# Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>, 2011, 2012, 2015, 2016, 2018.
|
# Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>, 2011, 2012, 2015, 2016, 2018.
|
||||||
|
# Carmen Bianca Bakker <carmen@carmenbianca.eu>, 2018.
|
||||||
|
#
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: gnome-shell master\n"
|
"Project-Id-Version: gnome-shell master\n"
|
||||||
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
||||||
"POT-Creation-Date: 2018-10-10 19:07+0000\n"
|
"POT-Creation-Date: 2018-11-26 21:23+0000\n"
|
||||||
"PO-Revision-Date: 2018-10-16 23:00+0200\n"
|
"PO-Revision-Date: 2018-11-27 13:32+0100\n"
|
||||||
"Last-Translator: Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>\n"
|
"Last-Translator: Carmen Bianca Bakker <carmen@carmenbianca.eu>\n"
|
||||||
"Language-Team: Esperanto <gnome-eo-list@gnome.org>\n"
|
"Language-Team: Esperanto <gnome-eo-list@gnome.org>\n"
|
||||||
"Language: eo\n"
|
"Language: eo\n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
|
||||||
"X-Generator: Virtaal 0.7.1\n"
|
"X-Generator: Gtranslator 3.30.1\n"
|
||||||
"X-DamnedLies-Scope: partial\n"
|
"X-DamnedLies-Scope: partial\n"
|
||||||
"X-Project-Style: gnome\n"
|
"X-Project-Style: gnome\n"
|
||||||
|
|
||||||
@@ -33,7 +35,7 @@ msgstr "Montri la sciig-liston"
|
|||||||
|
|
||||||
#: data/50-gnome-shell-system.xml:12
|
#: data/50-gnome-shell-system.xml:12
|
||||||
msgid "Focus the active notification"
|
msgid "Focus the active notification"
|
||||||
msgstr "Enfokusigi la aktivan sciigon"
|
msgstr "Fokusi la aktivan sciigon"
|
||||||
|
|
||||||
#: data/50-gnome-shell-system.xml:15
|
#: data/50-gnome-shell-system.xml:15
|
||||||
msgid "Show the overview"
|
msgid "Show the overview"
|
||||||
@@ -204,11 +206,11 @@ msgstr "Klavkombino por baskuligi la videblecon de la sciigolisto."
|
|||||||
|
|
||||||
#: data/org.gnome.shell.gschema.xml.in:130
|
#: data/org.gnome.shell.gschema.xml.in:130
|
||||||
msgid "Keybinding to focus the active notification"
|
msgid "Keybinding to focus the active notification"
|
||||||
msgstr "Klavkombino por enfokusigi la aktivan sciigon"
|
msgstr "Klavkombino por fokusi la aktivan sciigon"
|
||||||
|
|
||||||
#: data/org.gnome.shell.gschema.xml.in:131
|
#: data/org.gnome.shell.gschema.xml.in:131
|
||||||
msgid "Keybinding to focus the active notification."
|
msgid "Keybinding to focus the active notification."
|
||||||
msgstr "Klavkombino por enfokusigi la aktivan sciigon."
|
msgstr "Klavkombino por fokusi la aktivan sciigon."
|
||||||
|
|
||||||
#: data/org.gnome.shell.gschema.xml.in:137
|
#: data/org.gnome.shell.gschema.xml.in:137
|
||||||
msgid ""
|
msgid ""
|
||||||
@@ -607,23 +609,23 @@ msgstr "Oftaj"
|
|||||||
msgid "All"
|
msgid "All"
|
||||||
msgstr "Ĉiuj"
|
msgstr "Ĉiuj"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1887
|
#: js/ui/appDisplay.js:1889
|
||||||
msgid "New Window"
|
msgid "New Window"
|
||||||
msgstr "Nova fenestro"
|
msgstr "Nova fenestro"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1901
|
#: js/ui/appDisplay.js:1903
|
||||||
msgid "Launch using Dedicated Graphics Card"
|
msgid "Launch using Dedicated Graphics Card"
|
||||||
msgstr "Lanĉi uzante dediĉitan vidkarton"
|
msgstr "Lanĉi uzante dediĉitan vidkarton"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1928 js/ui/dash.js:285
|
#: js/ui/appDisplay.js:1930 js/ui/dash.js:287
|
||||||
msgid "Remove from Favorites"
|
msgid "Remove from Favorites"
|
||||||
msgstr "Forigi el preferataj"
|
msgstr "Forigi el preferataj"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1934
|
#: js/ui/appDisplay.js:1936
|
||||||
msgid "Add to Favorites"
|
msgid "Add to Favorites"
|
||||||
msgstr "Aldoni al preferataj"
|
msgstr "Aldoni al preferataj"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1944
|
#: js/ui/appDisplay.js:1946
|
||||||
msgid "Show Details"
|
msgid "Show Details"
|
||||||
msgstr "Montri detalojn"
|
msgstr "Montri detalojn"
|
||||||
|
|
||||||
@@ -943,14 +945,14 @@ msgstr "%s estas nun konata kiel %s"
|
|||||||
msgid "Windows"
|
msgid "Windows"
|
||||||
msgstr "Fenestroj"
|
msgstr "Fenestroj"
|
||||||
|
|
||||||
#: js/ui/dash.js:246 js/ui/dash.js:287
|
#: js/ui/dash.js:248 js/ui/dash.js:289
|
||||||
msgid "Show Applications"
|
msgid "Show Applications"
|
||||||
msgstr "Montri aplikaĵojn"
|
msgstr "Montri aplikaĵojn"
|
||||||
|
|
||||||
# Kiel macOS «dock”. --Carmen
|
# Kiel macOS «dock”. --Carmen
|
||||||
#. Translators: this is the name of the dock/favorites area on
|
#. Translators: this is the name of the dock/favorites area on
|
||||||
#. the left of the overview
|
#. the left of the overview
|
||||||
#: js/ui/dash.js:444
|
#: js/ui/dash.js:446
|
||||||
msgid "Dash"
|
msgid "Dash"
|
||||||
msgstr "Doko"
|
msgstr "Doko"
|
||||||
|
|
||||||
@@ -1324,7 +1326,7 @@ msgstr "Montri fonton"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Retpaĝo"
|
msgstr "Retpaĝo"
|
||||||
|
|
||||||
#: js/ui/messageTray.js:1495
|
#: js/ui/messageTray.js:1498
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Sisteminformoj"
|
msgstr "Sisteminformoj"
|
||||||
|
|
||||||
@@ -1426,7 +1428,7 @@ msgstr "Supra breto"
|
|||||||
#. "ON" and "OFF") or "toggle-switch-intl" (for toggle
|
#. "ON" and "OFF") or "toggle-switch-intl" (for toggle
|
||||||
#. switches containing "◯" and "|"). Other values will
|
#. switches containing "◯" and "|"). Other values will
|
||||||
#. simply result in invisible toggle switches.
|
#. simply result in invisible toggle switches.
|
||||||
#: js/ui/popupMenu.js:300
|
#: js/ui/popupMenu.js:301
|
||||||
msgid "toggle-switch-us"
|
msgid "toggle-switch-us"
|
||||||
msgstr "toggle-switch-intl"
|
msgstr "toggle-switch-intl"
|
||||||
|
|
||||||
@@ -1466,7 +1468,7 @@ msgid_plural "%d new notifications"
|
|||||||
msgstr[0] "%d nova sciigo"
|
msgstr[0] "%d nova sciigo"
|
||||||
msgstr[1] "%d novaj sciigoj"
|
msgstr[1] "%d novaj sciigoj"
|
||||||
|
|
||||||
#: js/ui/screenShield.js:451 js/ui/status/system.js:294
|
#: js/ui/screenShield.js:451 js/ui/status/system.js:297
|
||||||
msgid "Lock"
|
msgid "Lock"
|
||||||
msgstr "Ŝlosi"
|
msgstr "Ŝlosi"
|
||||||
|
|
||||||
@@ -1909,27 +1911,27 @@ msgstr "Malŝalti"
|
|||||||
msgid "Airplane Mode On"
|
msgid "Airplane Mode On"
|
||||||
msgstr "Aviadila reĝimo estas ŝaltita"
|
msgstr "Aviadila reĝimo estas ŝaltita"
|
||||||
|
|
||||||
#: js/ui/status/system.js:227
|
#: js/ui/status/system.js:230
|
||||||
msgid "Switch User"
|
msgid "Switch User"
|
||||||
msgstr "Ŝanĝi uzanton"
|
msgstr "Ŝanĝi uzanton"
|
||||||
|
|
||||||
#: js/ui/status/system.js:239
|
#: js/ui/status/system.js:242
|
||||||
msgid "Log Out"
|
msgid "Log Out"
|
||||||
msgstr "Adiaŭi"
|
msgstr "Adiaŭi"
|
||||||
|
|
||||||
#: js/ui/status/system.js:251
|
#: js/ui/status/system.js:254
|
||||||
msgid "Account Settings"
|
msgid "Account Settings"
|
||||||
msgstr "Kontoagordoj"
|
msgstr "Kontoagordoj"
|
||||||
|
|
||||||
#: js/ui/status/system.js:279
|
#: js/ui/status/system.js:282
|
||||||
msgid "Orientation Lock"
|
msgid "Orientation Lock"
|
||||||
msgstr "Orientiĝa ŝloso"
|
msgstr "Orientiĝa ŝloso"
|
||||||
|
|
||||||
#: js/ui/status/system.js:305
|
#: js/ui/status/system.js:308
|
||||||
msgid "Suspend"
|
msgid "Suspend"
|
||||||
msgstr "Dormeti"
|
msgstr "Dormeti"
|
||||||
|
|
||||||
#: js/ui/status/system.js:315
|
#: js/ui/status/system.js:318
|
||||||
msgid "Power Off"
|
msgid "Power Off"
|
||||||
msgstr "Malŝalti"
|
msgstr "Malŝalti"
|
||||||
|
|
||||||
@@ -2036,7 +2038,7 @@ msgstr[1] "Agordaj ŝanĝoj malfaritos post %d sekundoj"
|
|||||||
|
|
||||||
#. Translators: This represents the size of a window. The first number is
|
#. Translators: This represents the size of a window. The first number is
|
||||||
#. * the width of the window and the second is the height.
|
#. * the width of the window and the second is the height.
|
||||||
#: js/ui/windowManager.js:681
|
#: js/ui/windowManager.js:686
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d × %d"
|
msgid "%d × %d"
|
||||||
msgstr "%d × %d"
|
msgstr "%d × %d"
|
||||||
|
66
po/sl.po
@@ -8,8 +8,8 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: gnome-shell master\n"
|
"Project-Id-Version: gnome-shell master\n"
|
||||||
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
||||||
"POT-Creation-Date: 2018-10-25 16:21+0000\n"
|
"POT-Creation-Date: 2018-11-28 09:06+0000\n"
|
||||||
"PO-Revision-Date: 2018-10-25 19:58+0200\n"
|
"PO-Revision-Date: 2018-12-01 21:50+0100\n"
|
||||||
"Last-Translator: Matej Urbančič <mateju@svn.gnome.org>\n"
|
"Last-Translator: Matej Urbančič <mateju@svn.gnome.org>\n"
|
||||||
"Language-Team: Slovenian GNOME Translation Team <gnome-si@googlegroups.com>\n"
|
"Language-Team: Slovenian GNOME Translation Team <gnome-si@googlegroups.com>\n"
|
||||||
"Language: sl\n"
|
"Language: sl\n"
|
||||||
@@ -651,7 +651,7 @@ msgstr "Novo okno"
|
|||||||
msgid "Launch using Dedicated Graphics Card"
|
msgid "Launch using Dedicated Graphics Card"
|
||||||
msgstr "Zaženi z uporabo določene grafične kartice"
|
msgstr "Zaženi z uporabo določene grafične kartice"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1930 js/ui/dash.js:248
|
#: js/ui/appDisplay.js:1930 js/ui/dash.js:250
|
||||||
msgid "Remove from Favorites"
|
msgid "Remove from Favorites"
|
||||||
msgstr "Odstrani iz priljubljenih"
|
msgstr "Odstrani iz priljubljenih"
|
||||||
|
|
||||||
@@ -784,47 +784,47 @@ msgstr "%OB %Y"
|
|||||||
msgid "Previous month"
|
msgid "Previous month"
|
||||||
msgstr "Predhodni mesec"
|
msgstr "Predhodni mesec"
|
||||||
|
|
||||||
#: js/ui/calendar.js:457
|
#: js/ui/calendar.js:458
|
||||||
msgid "Next month"
|
msgid "Next month"
|
||||||
msgstr "Naslednji mesec"
|
msgstr "Naslednji mesec"
|
||||||
|
|
||||||
#: js/ui/calendar.js:610
|
#: js/ui/calendar.js:612
|
||||||
#, no-javascript-format
|
#, no-javascript-format
|
||||||
msgctxt "date day number format"
|
msgctxt "date day number format"
|
||||||
msgid "%d"
|
msgid "%d"
|
||||||
msgstr "%d"
|
msgstr "%d"
|
||||||
|
|
||||||
#: js/ui/calendar.js:665
|
#: js/ui/calendar.js:667
|
||||||
msgid "Week %V"
|
msgid "Week %V"
|
||||||
msgstr "Teden %V"
|
msgstr "Teden %V"
|
||||||
|
|
||||||
#. Translators: Shown in calendar event list for all day events
|
#. Translators: Shown in calendar event list for all day events
|
||||||
#. * Keep it short, best if you can use less then 10 characters
|
#. * Keep it short, best if you can use less then 10 characters
|
||||||
#.
|
#.
|
||||||
#: js/ui/calendar.js:734
|
#: js/ui/calendar.js:736
|
||||||
msgctxt "event list time"
|
msgctxt "event list time"
|
||||||
msgid "All Day"
|
msgid "All Day"
|
||||||
msgstr "Celodnevno"
|
msgstr "Celodnevno"
|
||||||
|
|
||||||
#: js/ui/calendar.js:869
|
#: js/ui/calendar.js:873
|
||||||
msgctxt "calendar heading"
|
msgctxt "calendar heading"
|
||||||
msgid "%A, %B %-d"
|
msgid "%A, %B %-d"
|
||||||
msgstr "%A, %d. %B"
|
msgstr "%A, %d. %B"
|
||||||
|
|
||||||
#: js/ui/calendar.js:873
|
#: js/ui/calendar.js:877
|
||||||
msgctxt "calendar heading"
|
msgctxt "calendar heading"
|
||||||
msgid "%A, %B %-d, %Y"
|
msgid "%A, %B %-d, %Y"
|
||||||
msgstr "%A, %d %B %Y"
|
msgstr "%A, %d %B %Y"
|
||||||
|
|
||||||
#: js/ui/calendar.js:1103
|
#: js/ui/calendar.js:1107
|
||||||
msgid "No Notifications"
|
msgid "No Notifications"
|
||||||
msgstr "Ni obvestil"
|
msgstr "Ni obvestil"
|
||||||
|
|
||||||
#: js/ui/calendar.js:1106
|
#: js/ui/calendar.js:1110
|
||||||
msgid "No Events"
|
msgid "No Events"
|
||||||
msgstr "Ni dogodkov"
|
msgstr "Ni dogodkov"
|
||||||
|
|
||||||
#: js/ui/calendar.js:1134
|
#: js/ui/calendar.js:1138
|
||||||
msgid "Clear All"
|
msgid "Clear All"
|
||||||
msgstr "Počisti vse"
|
msgstr "Počisti vse"
|
||||||
|
|
||||||
@@ -982,13 +982,13 @@ msgstr "%s je sedaj znan kot v %s"
|
|||||||
msgid "Windows"
|
msgid "Windows"
|
||||||
msgstr "Okna"
|
msgstr "Okna"
|
||||||
|
|
||||||
#: js/ui/dash.js:209 js/ui/dash.js:250
|
#: js/ui/dash.js:211 js/ui/dash.js:252
|
||||||
msgid "Show Applications"
|
msgid "Show Applications"
|
||||||
msgstr "Pokaži programe"
|
msgstr "Pokaži programe"
|
||||||
|
|
||||||
#. Translators: this is the name of the dock/favorites area on
|
#. Translators: this is the name of the dock/favorites area on
|
||||||
#. the left of the overview
|
#. the left of the overview
|
||||||
#: js/ui/dash.js:407
|
#: js/ui/dash.js:409
|
||||||
msgid "Dash"
|
msgid "Dash"
|
||||||
msgstr "Pregledna plošča"
|
msgstr "Pregledna plošča"
|
||||||
|
|
||||||
@@ -1379,7 +1379,7 @@ msgstr "Poglej vir"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Spletna stran"
|
msgstr "Spletna stran"
|
||||||
|
|
||||||
#: js/ui/messageTray.js:1481
|
#: js/ui/messageTray.js:1487
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Podrobnosti sistema"
|
msgstr "Podrobnosti sistema"
|
||||||
|
|
||||||
@@ -1525,7 +1525,7 @@ msgstr[1] "%d novo obvestilo"
|
|||||||
msgstr[2] "%d novi obvestili"
|
msgstr[2] "%d novi obvestili"
|
||||||
msgstr[3] "%d nova obvestila"
|
msgstr[3] "%d nova obvestila"
|
||||||
|
|
||||||
#: js/ui/screenShield.js:451 js/ui/status/system.js:294
|
#: js/ui/screenShield.js:451 js/ui/status/system.js:297
|
||||||
msgid "Lock"
|
msgid "Lock"
|
||||||
msgstr "Zakleni"
|
msgstr "Zakleni"
|
||||||
|
|
||||||
@@ -1663,11 +1663,11 @@ msgstr "Povezano"
|
|||||||
msgid "Brightness"
|
msgid "Brightness"
|
||||||
msgstr "Svetlost"
|
msgstr "Svetlost"
|
||||||
|
|
||||||
#: js/ui/status/keyboard.js:819
|
#: js/ui/status/keyboard.js:833
|
||||||
msgid "Keyboard"
|
msgid "Keyboard"
|
||||||
msgstr "Tipkovnica"
|
msgstr "Tipkovnica"
|
||||||
|
|
||||||
#: js/ui/status/keyboard.js:839
|
#: js/ui/status/keyboard.js:853
|
||||||
msgid "Show Keyboard Layout"
|
msgid "Show Keyboard Layout"
|
||||||
msgstr "Pokaži razporeditev tipkovnice"
|
msgstr "Pokaži razporeditev tipkovnice"
|
||||||
|
|
||||||
@@ -1942,25 +1942,29 @@ msgstr "Upravljanje napajanja"
|
|||||||
msgid "Fully Charged"
|
msgid "Fully Charged"
|
||||||
msgstr "Polno napolnjeno"
|
msgstr "Polno napolnjeno"
|
||||||
|
|
||||||
|
#: js/ui/status/power.js:74
|
||||||
|
msgid "Not Charging"
|
||||||
|
msgstr "Naprava se ne polni"
|
||||||
|
|
||||||
#. 0 is reported when UPower does not have enough data
|
#. 0 is reported when UPower does not have enough data
|
||||||
#. to estimate battery life
|
#. to estimate battery life
|
||||||
#: js/ui/status/power.js:75 js/ui/status/power.js:81
|
#: js/ui/status/power.js:77 js/ui/status/power.js:83
|
||||||
msgid "Estimating…"
|
msgid "Estimating…"
|
||||||
msgstr "Ocenjevanje …"
|
msgstr "Ocenjevanje …"
|
||||||
|
|
||||||
#. Translators: this is <hours>:<minutes> Remaining (<percentage>)
|
#. Translators: this is <hours>:<minutes> Remaining (<percentage>)
|
||||||
#: js/ui/status/power.js:89
|
#: js/ui/status/power.js:91
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d∶%02d Remaining (%d %%)"
|
msgid "%d∶%02d Remaining (%d %%)"
|
||||||
msgstr "Preostaja %d∶%02d (%d %%)"
|
msgstr "Preostaja %d∶%02d (%d %%)"
|
||||||
|
|
||||||
#. Translators: this is <hours>:<minutes> Until Full (<percentage>)
|
#. Translators: this is <hours>:<minutes> Until Full (<percentage>)
|
||||||
#: js/ui/status/power.js:94
|
#: js/ui/status/power.js:96
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d∶%02d Until Full (%d %%)"
|
msgid "%d∶%02d Until Full (%d %%)"
|
||||||
msgstr "%d∶%02d do polnosti (%d %%)"
|
msgstr "%d∶%02d do polnosti (%d %%)"
|
||||||
|
|
||||||
#: js/ui/status/power.js:122 js/ui/status/power.js:124
|
#: js/ui/status/power.js:124 js/ui/status/power.js:126
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d %%"
|
msgid "%d %%"
|
||||||
msgstr "%d %%"
|
msgstr "%d %%"
|
||||||
@@ -1980,27 +1984,27 @@ msgstr "Izklopi"
|
|||||||
msgid "Airplane Mode On"
|
msgid "Airplane Mode On"
|
||||||
msgstr "Letalski način je omogočen"
|
msgstr "Letalski način je omogočen"
|
||||||
|
|
||||||
#: js/ui/status/system.js:227
|
#: js/ui/status/system.js:230
|
||||||
msgid "Switch User"
|
msgid "Switch User"
|
||||||
msgstr "Preklopi uporabnika"
|
msgstr "Preklopi uporabnika"
|
||||||
|
|
||||||
#: js/ui/status/system.js:239
|
#: js/ui/status/system.js:242
|
||||||
msgid "Log Out"
|
msgid "Log Out"
|
||||||
msgstr "Odjava"
|
msgstr "Odjava"
|
||||||
|
|
||||||
#: js/ui/status/system.js:251
|
#: js/ui/status/system.js:254
|
||||||
msgid "Account Settings"
|
msgid "Account Settings"
|
||||||
msgstr "Nastavitve računa"
|
msgstr "Nastavitve računa"
|
||||||
|
|
||||||
#: js/ui/status/system.js:279
|
#: js/ui/status/system.js:282
|
||||||
msgid "Orientation Lock"
|
msgid "Orientation Lock"
|
||||||
msgstr "Zaklep položaja"
|
msgstr "Zaklep položaja"
|
||||||
|
|
||||||
#: js/ui/status/system.js:305
|
#: js/ui/status/system.js:308
|
||||||
msgid "Suspend"
|
msgid "Suspend"
|
||||||
msgstr "V pripravljenost"
|
msgstr "V pripravljenost"
|
||||||
|
|
||||||
#: js/ui/status/system.js:315
|
#: js/ui/status/system.js:318
|
||||||
msgid "Power Off"
|
msgid "Power Off"
|
||||||
msgstr "Izklop"
|
msgstr "Izklop"
|
||||||
|
|
||||||
@@ -2078,7 +2082,7 @@ msgstr "Programi"
|
|||||||
msgid "Search"
|
msgid "Search"
|
||||||
msgstr "Poišči"
|
msgstr "Poišči"
|
||||||
|
|
||||||
#: js/ui/windowAttentionHandler.js:20
|
#: js/ui/windowAttentionHandler.js:22
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "“%s” is ready"
|
msgid "“%s” is ready"
|
||||||
msgstr "Storitev “%s” je pripravljena"
|
msgstr "Storitev “%s” je pripravljena"
|
||||||
@@ -2109,7 +2113,7 @@ msgstr[3] "Spremembe nastavitev bodo povrnjene v %d sekundah."
|
|||||||
|
|
||||||
#. Translators: This represents the size of a window. The first number is
|
#. Translators: This represents the size of a window. The first number is
|
||||||
#. * the width of the window and the second is the height.
|
#. * the width of the window and the second is the height.
|
||||||
#: js/ui/windowManager.js:681
|
#: js/ui/windowManager.js:686
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d × %d"
|
msgid "%d × %d"
|
||||||
msgstr "%d × %d"
|
msgstr "%d × %d"
|
||||||
@@ -2221,7 +2225,7 @@ msgstr "Gesli nista skladni!"
|
|||||||
msgid "Password cannot be blank"
|
msgid "Password cannot be blank"
|
||||||
msgstr "Geslo ne more biti prazna vrednost"
|
msgstr "Geslo ne more biti prazna vrednost"
|
||||||
|
|
||||||
#: src/shell-polkit-authentication-agent.c:353
|
#: src/shell-polkit-authentication-agent.c:348
|
||||||
msgid "Authentication dialog was dismissed by the user"
|
msgid "Authentication dialog was dismissed by the user"
|
||||||
msgstr "Uporabnik je preklical pogovorno okno overitve"
|
msgstr "Uporabnik je preklical pogovorno okno overitve"
|
||||||
|
|
||||||
|
@@ -5,9 +5,6 @@
|
|||||||
#include "shell-app.h"
|
#include "shell-app.h"
|
||||||
#include "shell-app-system.h"
|
#include "shell-app-system.h"
|
||||||
|
|
||||||
#define SN_API_NOT_YET_FROZEN 1
|
|
||||||
#include <libsn/sn.h>
|
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
ShellApp* _shell_app_new_for_window (MetaWindow *window);
|
ShellApp* _shell_app_new_for_window (MetaWindow *window);
|
||||||
@@ -16,7 +13,7 @@ ShellApp* _shell_app_new (GDesktopAppInfo *info);
|
|||||||
|
|
||||||
void _shell_app_set_app_info (ShellApp *app, GDesktopAppInfo *info);
|
void _shell_app_set_app_info (ShellApp *app, GDesktopAppInfo *info);
|
||||||
|
|
||||||
void _shell_app_handle_startup_sequence (ShellApp *app, SnStartupSequence *sequence);
|
void _shell_app_handle_startup_sequence (ShellApp *app, MetaStartupSequence *sequence);
|
||||||
|
|
||||||
void _shell_app_add_window (ShellApp *app, MetaWindow *window);
|
void _shell_app_add_window (ShellApp *app, MetaWindow *window);
|
||||||
|
|
||||||
|
@@ -386,8 +386,7 @@ _shell_app_system_notify_app_state_changed (ShellAppSystem *self,
|
|||||||
* @self: A #ShellAppSystem
|
* @self: A #ShellAppSystem
|
||||||
*
|
*
|
||||||
* Returns the set of applications which currently have at least one
|
* Returns the set of applications which currently have at least one
|
||||||
* open window in the given context. The returned list will be sorted
|
* open window. The returned list will be sorted by shell_app_compare().
|
||||||
* by shell_app_compare().
|
|
||||||
*
|
*
|
||||||
* Returns: (element-type ShellApp) (transfer container): Active applications
|
* Returns: (element-type ShellApp) (transfer container): Active applications
|
||||||
*/
|
*/
|
||||||
|
@@ -82,21 +82,17 @@ struct _ShellAppUsage
|
|||||||
|
|
||||||
GFile *configfile;
|
GFile *configfile;
|
||||||
GDBusProxy *session_proxy;
|
GDBusProxy *session_proxy;
|
||||||
GdkDisplay *display;
|
|
||||||
GSettings *privacy_settings;
|
GSettings *privacy_settings;
|
||||||
gulong last_idle;
|
|
||||||
guint idle_focus_change_id;
|
guint idle_focus_change_id;
|
||||||
guint save_id;
|
guint save_id;
|
||||||
gboolean currently_idle;
|
gboolean currently_idle;
|
||||||
gboolean enable_monitoring;
|
gboolean enable_monitoring;
|
||||||
|
|
||||||
GSList *previously_running;
|
|
||||||
|
|
||||||
long watch_start_time;
|
long watch_start_time;
|
||||||
ShellApp *watched_app;
|
ShellApp *watched_app;
|
||||||
|
|
||||||
/* <char *context, GHashTable<char *appid, UsageData *usage>> */
|
/* <char *appid, UsageData *usage> */
|
||||||
GHashTable *app_usages_for_context;
|
GHashTable *app_usages;
|
||||||
};
|
};
|
||||||
|
|
||||||
G_DEFINE_TYPE (ShellAppUsage, shell_app_usage, G_TYPE_OBJECT);
|
G_DEFINE_TYPE (ShellAppUsage, shell_app_usage, G_TYPE_OBJECT);
|
||||||
@@ -104,11 +100,6 @@ G_DEFINE_TYPE (ShellAppUsage, shell_app_usage, G_TYPE_OBJECT);
|
|||||||
/* Represents an application record for a given context */
|
/* Represents an application record for a given context */
|
||||||
struct UsageData
|
struct UsageData
|
||||||
{
|
{
|
||||||
/* Whether the application we're tracking is "transient", see
|
|
||||||
* shell_app_is_window_backed.
|
|
||||||
*/
|
|
||||||
gboolean transient;
|
|
||||||
|
|
||||||
gdouble score; /* Based on the number of times we'e seen the app and normalized */
|
gdouble score; /* Based on the number of times we'e seen the app and normalized */
|
||||||
long last_seen; /* Used to clear old apps we've only seen a few times */
|
long last_seen; /* Used to clear old apps we've only seen a few times */
|
||||||
};
|
};
|
||||||
@@ -118,9 +109,6 @@ static void shell_app_usage_finalize (GObject *object);
|
|||||||
static void on_session_status_changed (GDBusProxy *proxy, guint status, ShellAppUsage *self);
|
static void on_session_status_changed (GDBusProxy *proxy, guint status, ShellAppUsage *self);
|
||||||
static void on_focus_app_changed (ShellWindowTracker *tracker, GParamSpec *spec, ShellAppUsage *self);
|
static void on_focus_app_changed (ShellWindowTracker *tracker, GParamSpec *spec, ShellAppUsage *self);
|
||||||
static void ensure_queued_save (ShellAppUsage *self);
|
static void ensure_queued_save (ShellAppUsage *self);
|
||||||
static UsageData * get_app_usage_for_context_and_id (ShellAppUsage *self,
|
|
||||||
const char *context,
|
|
||||||
const char *appid);
|
|
||||||
|
|
||||||
static gboolean idle_save_application_usage (gpointer data);
|
static gboolean idle_save_application_usage (gpointer data);
|
||||||
|
|
||||||
@@ -148,130 +136,34 @@ shell_app_usage_class_init (ShellAppUsageClass *klass)
|
|||||||
gobject_class->finalize = shell_app_usage_finalize;
|
gobject_class->finalize = shell_app_usage_finalize;
|
||||||
}
|
}
|
||||||
|
|
||||||
static GHashTable *
|
|
||||||
get_usages_for_context (ShellAppUsage *self,
|
|
||||||
const char *context)
|
|
||||||
{
|
|
||||||
GHashTable *context_usages;
|
|
||||||
|
|
||||||
context_usages = g_hash_table_lookup (self->app_usages_for_context, context);
|
|
||||||
if (context_usages == NULL)
|
|
||||||
{
|
|
||||||
context_usages = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_free);
|
|
||||||
g_hash_table_insert (self->app_usages_for_context, g_strdup (context),
|
|
||||||
context_usages);
|
|
||||||
}
|
|
||||||
return context_usages;
|
|
||||||
}
|
|
||||||
|
|
||||||
static UsageData *
|
|
||||||
get_app_usage_for_context_and_id (ShellAppUsage *self,
|
|
||||||
const char *context,
|
|
||||||
const char *appid)
|
|
||||||
{
|
|
||||||
UsageData *usage;
|
|
||||||
GHashTable *context_usages;
|
|
||||||
|
|
||||||
context_usages = get_usages_for_context (self, context);
|
|
||||||
|
|
||||||
usage = g_hash_table_lookup (context_usages, appid);
|
|
||||||
if (usage)
|
|
||||||
return usage;
|
|
||||||
|
|
||||||
usage = g_new0 (UsageData, 1);
|
|
||||||
g_hash_table_insert (context_usages, g_strdup (appid), usage);
|
|
||||||
|
|
||||||
return usage;
|
|
||||||
}
|
|
||||||
|
|
||||||
static UsageData *
|
static UsageData *
|
||||||
get_usage_for_app (ShellAppUsage *self,
|
get_usage_for_app (ShellAppUsage *self,
|
||||||
ShellApp *app)
|
ShellApp *app)
|
||||||
{
|
{
|
||||||
const char *context;
|
UsageData *usage;
|
||||||
|
const char *appid = shell_app_get_id (app);
|
||||||
|
|
||||||
context = _shell_window_tracker_get_app_context (shell_window_tracker_get_default (), app);
|
usage = g_hash_table_lookup (self->app_usages, appid);
|
||||||
|
if (usage)
|
||||||
|
return usage;
|
||||||
|
|
||||||
return get_app_usage_for_context_and_id (self, context, shell_app_get_id (app));
|
usage = g_new0 (UsageData, 1);
|
||||||
}
|
g_hash_table_insert (self->app_usages, g_strdup (appid), usage);
|
||||||
|
|
||||||
typedef struct {
|
return usage;
|
||||||
gboolean in_context;
|
|
||||||
GHashTableIter context_iter;
|
|
||||||
const char *context_id;
|
|
||||||
GHashTableIter usage_iter;
|
|
||||||
} UsageIterator;
|
|
||||||
|
|
||||||
static void
|
|
||||||
usage_iterator_init (ShellAppUsage *self,
|
|
||||||
UsageIterator *iter)
|
|
||||||
{
|
|
||||||
iter->in_context = FALSE;
|
|
||||||
g_hash_table_iter_init (&(iter->context_iter), self->app_usages_for_context);
|
|
||||||
}
|
|
||||||
|
|
||||||
static gboolean
|
|
||||||
usage_iterator_next (ShellAppUsage *self,
|
|
||||||
UsageIterator *iter,
|
|
||||||
const char **context,
|
|
||||||
const char **id,
|
|
||||||
UsageData **usage)
|
|
||||||
{
|
|
||||||
gpointer key, value;
|
|
||||||
gboolean next_context;
|
|
||||||
|
|
||||||
if (!iter->in_context)
|
|
||||||
next_context = TRUE;
|
|
||||||
else if (!g_hash_table_iter_next (&(iter->usage_iter), &key, &value))
|
|
||||||
next_context = TRUE;
|
|
||||||
else
|
|
||||||
next_context = FALSE;
|
|
||||||
|
|
||||||
while (next_context)
|
|
||||||
{
|
|
||||||
GHashTable *app_usages;
|
|
||||||
|
|
||||||
if (!g_hash_table_iter_next (&(iter->context_iter), &key, &value))
|
|
||||||
return FALSE;
|
|
||||||
iter->in_context = TRUE;
|
|
||||||
iter->context_id = key;
|
|
||||||
app_usages = value;
|
|
||||||
g_hash_table_iter_init (&(iter->usage_iter), app_usages);
|
|
||||||
|
|
||||||
next_context = !g_hash_table_iter_next (&(iter->usage_iter), &key, &value);
|
|
||||||
}
|
|
||||||
|
|
||||||
*context = iter->context_id;
|
|
||||||
*id = key;
|
|
||||||
*usage = value;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
usage_iterator_remove (ShellAppUsage *self,
|
|
||||||
UsageIterator *iter)
|
|
||||||
{
|
|
||||||
g_assert (iter->in_context);
|
|
||||||
|
|
||||||
g_hash_table_iter_remove (&(iter->usage_iter));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Limit the score to a certain level so that most used apps can change */
|
/* Limit the score to a certain level so that most used apps can change */
|
||||||
static void
|
static void
|
||||||
normalize_usage (ShellAppUsage *self)
|
normalize_usage (ShellAppUsage *self)
|
||||||
{
|
{
|
||||||
UsageIterator iter;
|
GHashTableIter iter;
|
||||||
const char *context;
|
|
||||||
const char *id;
|
|
||||||
UsageData *usage;
|
UsageData *usage;
|
||||||
|
|
||||||
usage_iterator_init (self, &iter);
|
g_hash_table_iter_init (&iter, self->app_usages);
|
||||||
|
|
||||||
while (usage_iterator_next (self, &iter, &context, &id, &usage))
|
while (g_hash_table_iter_next (&iter, NULL, (gpointer *) &usage))
|
||||||
{
|
usage->score /= 2;
|
||||||
usage->score /= 2;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@@ -395,7 +287,7 @@ shell_app_usage_init (ShellAppUsage *self)
|
|||||||
|
|
||||||
global = shell_global_get ();
|
global = shell_global_get ();
|
||||||
|
|
||||||
self->app_usages_for_context = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, (GDestroyNotify) g_hash_table_destroy);
|
self->app_usages = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_free);
|
||||||
|
|
||||||
tracker = shell_window_tracker_get_default ();
|
tracker = shell_window_tracker_get_default ();
|
||||||
g_signal_connect (tracker, "notify::focus-app", G_CALLBACK (on_focus_app_changed), self);
|
g_signal_connect (tracker, "notify::focus-app", G_CALLBACK (on_focus_app_changed), self);
|
||||||
@@ -415,7 +307,6 @@ shell_app_usage_init (ShellAppUsage *self)
|
|||||||
g_signal_connect (self->session_proxy, "g-signal", G_CALLBACK (session_proxy_signal), self);
|
g_signal_connect (self->session_proxy, "g-signal", G_CALLBACK (session_proxy_signal), self);
|
||||||
g_object_unref (session_bus);
|
g_object_unref (session_bus);
|
||||||
|
|
||||||
self->last_idle = 0;
|
|
||||||
self->currently_idle = FALSE;
|
self->currently_idle = FALSE;
|
||||||
self->enable_monitoring = FALSE;
|
self->enable_monitoring = FALSE;
|
||||||
|
|
||||||
@@ -451,25 +342,20 @@ shell_app_usage_finalize (GObject *object)
|
|||||||
G_OBJECT_CLASS (shell_app_usage_parent_class)->finalize(object);
|
G_OBJECT_CLASS (shell_app_usage_parent_class)->finalize(object);
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
ShellAppUsage *usage;
|
|
||||||
GHashTable *context_usages;
|
|
||||||
} SortAppsByUsageData;
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
sort_apps_by_usage (gconstpointer a,
|
sort_apps_by_usage (gconstpointer a,
|
||||||
gconstpointer b,
|
gconstpointer b,
|
||||||
gpointer datap)
|
gpointer datap)
|
||||||
{
|
{
|
||||||
SortAppsByUsageData *data = datap;
|
ShellAppUsage *self = datap;
|
||||||
ShellApp *app_a, *app_b;
|
ShellApp *app_a, *app_b;
|
||||||
UsageData *usage_a, *usage_b;
|
UsageData *usage_a, *usage_b;
|
||||||
|
|
||||||
app_a = (ShellApp*)a;
|
app_a = (ShellApp*)a;
|
||||||
app_b = (ShellApp*)b;
|
app_b = (ShellApp*)b;
|
||||||
|
|
||||||
usage_a = g_hash_table_lookup (data->context_usages, shell_app_get_id (app_a));
|
usage_a = g_hash_table_lookup (self->app_usages, shell_app_get_id (app_a));
|
||||||
usage_b = g_hash_table_lookup (data->context_usages, shell_app_get_id (app_b));
|
usage_b = g_hash_table_lookup (self->app_usages, shell_app_get_id (app_b));
|
||||||
|
|
||||||
return usage_b->score - usage_a->score;
|
return usage_b->score - usage_a->score;
|
||||||
}
|
}
|
||||||
@@ -477,33 +363,23 @@ sort_apps_by_usage (gconstpointer a,
|
|||||||
/**
|
/**
|
||||||
* shell_app_usage_get_most_used:
|
* shell_app_usage_get_most_used:
|
||||||
* @usage: the usage instance to request
|
* @usage: the usage instance to request
|
||||||
* @context: Activity identifier
|
|
||||||
*
|
|
||||||
* Get a list of most popular applications for a given context.
|
|
||||||
*
|
*
|
||||||
* Returns: (element-type ShellApp) (transfer full): List of applications
|
* Returns: (element-type ShellApp) (transfer full): List of applications
|
||||||
*/
|
*/
|
||||||
GSList *
|
GSList *
|
||||||
shell_app_usage_get_most_used (ShellAppUsage *self,
|
shell_app_usage_get_most_used (ShellAppUsage *self)
|
||||||
const char *context)
|
|
||||||
{
|
{
|
||||||
GSList *apps;
|
GSList *apps;
|
||||||
GList *appids, *iter;
|
char *appid;
|
||||||
GHashTable *usages;
|
|
||||||
ShellAppSystem *appsys;
|
ShellAppSystem *appsys;
|
||||||
SortAppsByUsageData data;
|
GHashTableIter iter;
|
||||||
|
|
||||||
usages = g_hash_table_lookup (self->app_usages_for_context, context);
|
|
||||||
if (usages == NULL)
|
|
||||||
return NULL;
|
|
||||||
|
|
||||||
appsys = shell_app_system_get_default ();
|
appsys = shell_app_system_get_default ();
|
||||||
|
|
||||||
appids = g_hash_table_get_keys (usages);
|
g_hash_table_iter_init (&iter, self->app_usages);
|
||||||
apps = NULL;
|
apps = NULL;
|
||||||
for (iter = appids; iter; iter = iter->next)
|
while (g_hash_table_iter_next (&iter, (gpointer *) &appid, NULL))
|
||||||
{
|
{
|
||||||
const char *appid = iter->data;
|
|
||||||
ShellApp *app;
|
ShellApp *app;
|
||||||
|
|
||||||
app = shell_app_system_lookup_app (appsys, appid);
|
app = shell_app_system_lookup_app (appsys, appid);
|
||||||
@@ -513,11 +389,7 @@ shell_app_usage_get_most_used (ShellAppUsage *self,
|
|||||||
apps = g_slist_prepend (apps, g_object_ref (app));
|
apps = g_slist_prepend (apps, g_object_ref (app));
|
||||||
}
|
}
|
||||||
|
|
||||||
g_list_free (appids);
|
apps = g_slist_sort_with_data (apps, sort_apps_by_usage, self);
|
||||||
|
|
||||||
data.usage = self;
|
|
||||||
data.context_usages = usages;
|
|
||||||
apps = g_slist_sort_with_data (apps, sort_apps_by_usage, &data);
|
|
||||||
|
|
||||||
return apps;
|
return apps;
|
||||||
}
|
}
|
||||||
@@ -526,7 +398,6 @@ shell_app_usage_get_most_used (ShellAppUsage *self,
|
|||||||
/**
|
/**
|
||||||
* shell_app_usage_compare:
|
* shell_app_usage_compare:
|
||||||
* @self: the usage instance to request
|
* @self: the usage instance to request
|
||||||
* @context: Activity identifier
|
|
||||||
* @id_a: ID of first app
|
* @id_a: ID of first app
|
||||||
* @id_b: ID of second app
|
* @id_b: ID of second app
|
||||||
*
|
*
|
||||||
@@ -537,19 +408,13 @@ shell_app_usage_get_most_used (ShellAppUsage *self,
|
|||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
shell_app_usage_compare (ShellAppUsage *self,
|
shell_app_usage_compare (ShellAppUsage *self,
|
||||||
const char *context,
|
|
||||||
const char *id_a,
|
const char *id_a,
|
||||||
const char *id_b)
|
const char *id_b)
|
||||||
{
|
{
|
||||||
GHashTable *usages;
|
|
||||||
UsageData *usage_a, *usage_b;
|
UsageData *usage_a, *usage_b;
|
||||||
|
|
||||||
usages = g_hash_table_lookup (self->app_usages_for_context, context);
|
usage_a = g_hash_table_lookup (self->app_usages, id_a);
|
||||||
if (usages == NULL)
|
usage_b = g_hash_table_lookup (self->app_usages, id_b);
|
||||||
return 0;
|
|
||||||
|
|
||||||
usage_a = g_hash_table_lookup (usages, id_a);
|
|
||||||
usage_b = g_hash_table_lookup (usages, id_b);
|
|
||||||
|
|
||||||
if (usage_a == NULL && usage_b == NULL)
|
if (usage_a == NULL && usage_b == NULL)
|
||||||
return 0;
|
return 0;
|
||||||
@@ -577,9 +442,7 @@ ensure_queued_save (ShellAppUsage *self)
|
|||||||
static gboolean
|
static gboolean
|
||||||
idle_clean_usage (ShellAppUsage *self)
|
idle_clean_usage (ShellAppUsage *self)
|
||||||
{
|
{
|
||||||
UsageIterator iter;
|
GHashTableIter iter;
|
||||||
const char *context;
|
|
||||||
const char *id;
|
|
||||||
UsageData *usage;
|
UsageData *usage;
|
||||||
long current_time;
|
long current_time;
|
||||||
long week_ago;
|
long week_ago;
|
||||||
@@ -587,13 +450,13 @@ idle_clean_usage (ShellAppUsage *self)
|
|||||||
current_time = get_time ();
|
current_time = get_time ();
|
||||||
week_ago = current_time - (7 * 24 * 60 * 60);
|
week_ago = current_time - (7 * 24 * 60 * 60);
|
||||||
|
|
||||||
usage_iterator_init (self, &iter);
|
g_hash_table_iter_init (&iter, self->app_usages);
|
||||||
|
|
||||||
while (usage_iterator_next (self, &iter, &context, &id, &usage))
|
while (g_hash_table_iter_next (&iter, NULL, (gpointer *) &usage))
|
||||||
{
|
{
|
||||||
if ((usage->score < SCORE_MIN) &&
|
if ((usage->score < SCORE_MIN) &&
|
||||||
(usage->last_seen < week_ago))
|
(usage->last_seen < week_ago))
|
||||||
usage_iterator_remove (self, &iter);
|
g_hash_table_iter_remove (&iter);
|
||||||
}
|
}
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
@@ -672,10 +535,8 @@ static gboolean
|
|||||||
idle_save_application_usage (gpointer data)
|
idle_save_application_usage (gpointer data)
|
||||||
{
|
{
|
||||||
ShellAppUsage *self = SHELL_APP_USAGE (data);
|
ShellAppUsage *self = SHELL_APP_USAGE (data);
|
||||||
UsageIterator iter;
|
char *id;
|
||||||
const char *current_context;
|
GHashTableIter iter;
|
||||||
const char *context;
|
|
||||||
const char *id;
|
|
||||||
UsageData *usage;
|
UsageData *usage;
|
||||||
GFileOutputStream *output;
|
GFileOutputStream *output;
|
||||||
GOutputStream *buffered_output;
|
GOutputStream *buffered_output;
|
||||||
@@ -699,11 +560,12 @@ idle_save_application_usage (gpointer data)
|
|||||||
|
|
||||||
if (!g_data_output_stream_put_string (data_output, "<?xml version=\"1.0\"?>\n<application-state>\n", NULL, &error))
|
if (!g_data_output_stream_put_string (data_output, "<?xml version=\"1.0\"?>\n<application-state>\n", NULL, &error))
|
||||||
goto out;
|
goto out;
|
||||||
|
if (!g_data_output_stream_put_string (data_output, " <context id=\"\">\n", NULL, &error))
|
||||||
|
goto out;
|
||||||
|
|
||||||
usage_iterator_init (self, &iter);
|
g_hash_table_iter_init (&iter, self->app_usages);
|
||||||
|
|
||||||
current_context = NULL;
|
while (g_hash_table_iter_next (&iter, (gpointer *) &id, (gpointer *) &usage))
|
||||||
while (usage_iterator_next (self, &iter, &context, &id, &usage))
|
|
||||||
{
|
{
|
||||||
ShellApp *app;
|
ShellApp *app;
|
||||||
|
|
||||||
@@ -712,28 +574,10 @@ idle_save_application_usage (gpointer data)
|
|||||||
if (!app)
|
if (!app)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (context != current_context)
|
|
||||||
{
|
|
||||||
if (current_context != NULL)
|
|
||||||
{
|
|
||||||
if (!g_data_output_stream_put_string (data_output, " </context>", NULL, &error))
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
current_context = context;
|
|
||||||
if (!g_data_output_stream_put_string (data_output, " <context", NULL, &error))
|
|
||||||
goto out;
|
|
||||||
if (!write_attribute_string (data_output, "id", context, &error))
|
|
||||||
goto out;
|
|
||||||
if (!g_data_output_stream_put_string (data_output, ">\n", NULL, &error))
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
if (!g_data_output_stream_put_string (data_output, " <application", NULL, &error))
|
if (!g_data_output_stream_put_string (data_output, " <application", NULL, &error))
|
||||||
goto out;
|
goto out;
|
||||||
if (!write_attribute_string (data_output, "id", id, &error))
|
if (!write_attribute_string (data_output, "id", id, &error))
|
||||||
goto out;
|
goto out;
|
||||||
if (!write_attribute_uint (data_output, "open-window-count", shell_app_get_n_windows (app), &error))
|
|
||||||
goto out;
|
|
||||||
|
|
||||||
if (!write_attribute_double (data_output, "score", usage->score, &error))
|
if (!write_attribute_double (data_output, "score", usage->score, &error))
|
||||||
goto out;
|
goto out;
|
||||||
if (!write_attribute_uint (data_output, "last-seen", usage->last_seen, &error))
|
if (!write_attribute_uint (data_output, "last-seen", usage->last_seen, &error))
|
||||||
@@ -741,11 +585,8 @@ idle_save_application_usage (gpointer data)
|
|||||||
if (!g_data_output_stream_put_string (data_output, "/>\n", NULL, &error))
|
if (!g_data_output_stream_put_string (data_output, "/>\n", NULL, &error))
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
if (current_context != NULL)
|
if (!g_data_output_stream_put_string (data_output, " </context>\n", NULL, &error))
|
||||||
{
|
goto out;
|
||||||
if (!g_data_output_stream_put_string (data_output, " </context>\n", NULL, &error))
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
if (!g_data_output_stream_put_string (data_output, "</application-state>\n", NULL, &error))
|
if (!g_data_output_stream_put_string (data_output, "</application-state>\n", NULL, &error))
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
@@ -761,48 +602,21 @@ out:
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
ShellAppUsage *self;
|
|
||||||
char *context;
|
|
||||||
} ParseData;
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
shell_app_usage_start_element_handler (GMarkupParseContext *context,
|
shell_app_usage_start_element_handler (GMarkupParseContext *context,
|
||||||
const gchar *element_name,
|
const gchar *element_name,
|
||||||
const gchar **attribute_names,
|
const gchar **attribute_names,
|
||||||
const gchar **attribute_values,
|
const gchar **attribute_values,
|
||||||
gpointer user_data,
|
gpointer user_data,
|
||||||
GError **error)
|
GError **error)
|
||||||
{
|
{
|
||||||
ParseData *data = user_data;
|
ShellAppUsage *self = user_data;
|
||||||
|
|
||||||
if (strcmp (element_name, "application-state") == 0)
|
if (strcmp (element_name, "application-state") == 0)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
else if (strcmp (element_name, "context") == 0)
|
else if (strcmp (element_name, "context") == 0)
|
||||||
{
|
{
|
||||||
char *id = NULL;
|
|
||||||
const char **attribute;
|
|
||||||
const char **value;
|
|
||||||
|
|
||||||
for (attribute = attribute_names, value = attribute_values; *attribute; attribute++, value++)
|
|
||||||
{
|
|
||||||
if (strcmp (*attribute, "id") == 0)
|
|
||||||
{
|
|
||||||
id = g_strdup (*value);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!id)
|
|
||||||
{
|
|
||||||
g_set_error (error,
|
|
||||||
G_MARKUP_ERROR,
|
|
||||||
G_MARKUP_ERROR_PARSE,
|
|
||||||
"Missing attribute id on <%s> element",
|
|
||||||
element_name);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
data->context = id;
|
|
||||||
}
|
}
|
||||||
else if (strcmp (element_name, "application") == 0)
|
else if (strcmp (element_name, "application") == 0)
|
||||||
{
|
{
|
||||||
@@ -810,7 +624,6 @@ shell_app_usage_start_element_handler (GMarkupParseContext *context,
|
|||||||
const char **value;
|
const char **value;
|
||||||
UsageData *usage;
|
UsageData *usage;
|
||||||
char *appid = NULL;
|
char *appid = NULL;
|
||||||
GHashTable *usage_table;
|
|
||||||
|
|
||||||
for (attribute = attribute_names, value = attribute_values; *attribute; attribute++, value++)
|
for (attribute = attribute_names, value = attribute_values; *attribute; attribute++, value++)
|
||||||
{
|
{
|
||||||
@@ -831,21 +644,12 @@ shell_app_usage_start_element_handler (GMarkupParseContext *context,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
usage_table = get_usages_for_context (data->self, data->context);
|
|
||||||
|
|
||||||
usage = g_new0 (UsageData, 1);
|
usage = g_new0 (UsageData, 1);
|
||||||
g_hash_table_insert (usage_table, appid, usage);
|
g_hash_table_insert (self->app_usages, appid, usage);
|
||||||
|
|
||||||
for (attribute = attribute_names, value = attribute_values; *attribute; attribute++, value++)
|
for (attribute = attribute_names, value = attribute_values; *attribute; attribute++, value++)
|
||||||
{
|
{
|
||||||
if (strcmp (*attribute, "open-window-count") == 0)
|
if (strcmp (*attribute, "score") == 0)
|
||||||
{
|
|
||||||
guint count = strtoul (*value, NULL, 10);
|
|
||||||
if (count > 0)
|
|
||||||
data->self->previously_running = g_slist_prepend (data->self->previously_running,
|
|
||||||
g_strdup (appid));
|
|
||||||
}
|
|
||||||
else if (strcmp (*attribute, "score") == 0)
|
|
||||||
{
|
{
|
||||||
usage->score = g_ascii_strtod (*value, NULL);
|
usage->score = g_ascii_strtod (*value, NULL);
|
||||||
}
|
}
|
||||||
@@ -865,36 +669,11 @@ shell_app_usage_start_element_handler (GMarkupParseContext *context,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
shell_app_usage_end_element_handler (GMarkupParseContext *context,
|
|
||||||
const gchar *element_name,
|
|
||||||
gpointer user_data,
|
|
||||||
GError **error)
|
|
||||||
{
|
|
||||||
ParseData *data = user_data;
|
|
||||||
|
|
||||||
if (strcmp (element_name, "context") == 0)
|
|
||||||
{
|
|
||||||
g_free (data->context);
|
|
||||||
data->context = NULL;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
shell_app_usage_text_handler (GMarkupParseContext *context,
|
|
||||||
const gchar *text,
|
|
||||||
gsize text_len,
|
|
||||||
gpointer user_data,
|
|
||||||
GError **error)
|
|
||||||
{
|
|
||||||
/* do nothing, very very fast */
|
|
||||||
}
|
|
||||||
|
|
||||||
static GMarkupParser app_state_parse_funcs =
|
static GMarkupParser app_state_parse_funcs =
|
||||||
{
|
{
|
||||||
shell_app_usage_start_element_handler,
|
shell_app_usage_start_element_handler,
|
||||||
shell_app_usage_end_element_handler,
|
NULL,
|
||||||
shell_app_usage_text_handler,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
@@ -904,7 +683,6 @@ static void
|
|||||||
restore_from_file (ShellAppUsage *self)
|
restore_from_file (ShellAppUsage *self)
|
||||||
{
|
{
|
||||||
GFileInputStream *input;
|
GFileInputStream *input;
|
||||||
ParseData parse_data;
|
|
||||||
GMarkupParseContext *parse_context;
|
GMarkupParseContext *parse_context;
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
char buf[1024];
|
char buf[1024];
|
||||||
@@ -919,10 +697,7 @@ restore_from_file (ShellAppUsage *self)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
memset (&parse_data, 0, sizeof (ParseData));
|
parse_context = g_markup_parse_context_new (&app_state_parse_funcs, 0, self, NULL);
|
||||||
parse_data.self = self;
|
|
||||||
parse_data.context = NULL;
|
|
||||||
parse_context = g_markup_parse_context_new (&app_state_parse_funcs, 0, &parse_data, NULL);
|
|
||||||
|
|
||||||
while (TRUE)
|
while (TRUE)
|
||||||
{
|
{
|
||||||
@@ -934,7 +709,6 @@ restore_from_file (ShellAppUsage *self)
|
|||||||
}
|
}
|
||||||
|
|
||||||
out:
|
out:
|
||||||
g_free (parse_data.context);
|
|
||||||
g_markup_parse_context_free (parse_context);
|
g_markup_parse_context_free (parse_context);
|
||||||
g_input_stream_close ((GInputStream*)input, NULL, NULL);
|
g_input_stream_close ((GInputStream*)input, NULL, NULL);
|
||||||
g_object_unref (input);
|
g_object_unref (input);
|
||||||
|
@@ -13,10 +13,8 @@ G_DECLARE_FINAL_TYPE (ShellAppUsage, shell_app_usage,
|
|||||||
|
|
||||||
ShellAppUsage* shell_app_usage_get_default(void);
|
ShellAppUsage* shell_app_usage_get_default(void);
|
||||||
|
|
||||||
GSList *shell_app_usage_get_most_used (ShellAppUsage *usage,
|
GSList *shell_app_usage_get_most_used (ShellAppUsage *usage);
|
||||||
const char *context);
|
|
||||||
int shell_app_usage_compare (ShellAppUsage *self,
|
int shell_app_usage_compare (ShellAppUsage *self,
|
||||||
const char *context,
|
|
||||||
const char *id_a,
|
const char *id_a,
|
||||||
const char *id_b);
|
const char *id_b);
|
||||||
|
|
||||||
|
@@ -1142,10 +1142,10 @@ shell_app_get_pids (ShellApp *app)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_app_handle_startup_sequence (ShellApp *app,
|
_shell_app_handle_startup_sequence (ShellApp *app,
|
||||||
SnStartupSequence *sequence)
|
MetaStartupSequence *sequence)
|
||||||
{
|
{
|
||||||
gboolean starting = !sn_startup_sequence_get_completed (sequence);
|
gboolean starting = !meta_startup_sequence_get_completed (sequence);
|
||||||
|
|
||||||
/* The Shell design calls for on application launch, the app title
|
/* The Shell design calls for on application launch, the app title
|
||||||
* appears at top, and no X window is focused. So when we get
|
* appears at top, and no X window is focused. So when we get
|
||||||
@@ -1160,8 +1160,8 @@ _shell_app_handle_startup_sequence (ShellApp *app,
|
|||||||
|
|
||||||
shell_app_state_transition (app, SHELL_APP_STATE_STARTING);
|
shell_app_state_transition (app, SHELL_APP_STATE_STARTING);
|
||||||
meta_x11_display_focus_the_no_focus_window (x11_display,
|
meta_x11_display_focus_the_no_focus_window (x11_display,
|
||||||
sn_startup_sequence_get_timestamp (sequence));
|
meta_startup_sequence_get_timestamp (sequence));
|
||||||
app->started_on_workspace = sn_startup_sequence_get_workspace (sequence);
|
app->started_on_workspace = meta_startup_sequence_get_workspace (sequence);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!starting)
|
if (!starting)
|
||||||
|
@@ -14,9 +14,7 @@
|
|||||||
#include <meta/util.h>
|
#include <meta/util.h>
|
||||||
#include <meta/window.h>
|
#include <meta/window.h>
|
||||||
#include <meta/meta-workspace-manager.h>
|
#include <meta/meta-workspace-manager.h>
|
||||||
|
#include <meta/meta-startup-notification.h>
|
||||||
#define SN_API_NOT_YET_FROZEN 1
|
|
||||||
#include <libsn/sn.h>
|
|
||||||
|
|
||||||
#include "shell-window-tracker-private.h"
|
#include "shell-window-tracker-private.h"
|
||||||
#include "shell-app-private.h"
|
#include "shell-app-private.h"
|
||||||
@@ -74,6 +72,7 @@ static void on_focus_window_changed (MetaDisplay *display, GParamSpec *spec, She
|
|||||||
static void track_window (ShellWindowTracker *tracker, MetaWindow *window);
|
static void track_window (ShellWindowTracker *tracker, MetaWindow *window);
|
||||||
static void disassociate_window (ShellWindowTracker *tracker, MetaWindow *window);
|
static void disassociate_window (ShellWindowTracker *tracker, MetaWindow *window);
|
||||||
|
|
||||||
|
static ShellApp * shell_startup_sequence_get_app (MetaStartupSequence *sequence);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
shell_window_tracker_get_property (GObject *gobject,
|
shell_window_tracker_get_property (GObject *gobject,
|
||||||
@@ -115,7 +114,7 @@ shell_window_tracker_class_init (ShellWindowTrackerClass *klass)
|
|||||||
G_SIGNAL_RUN_LAST,
|
G_SIGNAL_RUN_LAST,
|
||||||
0,
|
0,
|
||||||
NULL, NULL, NULL,
|
NULL, NULL, NULL,
|
||||||
G_TYPE_NONE, 1, SHELL_TYPE_STARTUP_SEQUENCE);
|
G_TYPE_NONE, 1, META_TYPE_STARTUP_SEQUENCE);
|
||||||
signals[TRACKED_WINDOWS_CHANGED] = g_signal_new ("tracked-windows-changed",
|
signals[TRACKED_WINDOWS_CHANGED] = g_signal_new ("tracked-windows-changed",
|
||||||
SHELL_TYPE_WINDOW_TRACKER,
|
SHELL_TYPE_WINDOW_TRACKER,
|
||||||
G_SIGNAL_RUN_LAST,
|
G_SIGNAL_RUN_LAST,
|
||||||
@@ -430,8 +429,8 @@ get_app_for_window (ShellWindowTracker *tracker,
|
|||||||
sequences = shell_window_tracker_get_startup_sequences (tracker);
|
sequences = shell_window_tracker_get_startup_sequences (tracker);
|
||||||
for (iter = sequences; iter; iter = iter->next)
|
for (iter = sequences; iter; iter = iter->next)
|
||||||
{
|
{
|
||||||
ShellStartupSequence *sequence = iter->data;
|
MetaStartupSequence *sequence = iter->data;
|
||||||
const char *id = shell_startup_sequence_get_id (sequence);
|
const char *id = meta_startup_sequence_get_id (sequence);
|
||||||
if (strcmp (id, startup_id) != 0)
|
if (strcmp (id, startup_id) != 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
@@ -457,12 +456,6 @@ get_app_for_window (ShellWindowTracker *tracker,
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
const char *
|
|
||||||
_shell_window_tracker_get_app_context (ShellWindowTracker *tracker, ShellApp *app)
|
|
||||||
{
|
|
||||||
return "";
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
update_focus_app (ShellWindowTracker *self)
|
update_focus_app (ShellWindowTracker *self)
|
||||||
{
|
{
|
||||||
@@ -659,13 +652,13 @@ init_window_tracking (ShellWindowTracker *self)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
on_startup_sequence_changed (MetaDisplay *display,
|
on_startup_sequence_changed (MetaStartupNotification *sn,
|
||||||
SnStartupSequence *sequence,
|
MetaStartupSequence *sequence,
|
||||||
ShellWindowTracker *self)
|
ShellWindowTracker *self)
|
||||||
{
|
{
|
||||||
ShellApp *app;
|
ShellApp *app;
|
||||||
|
|
||||||
app = shell_startup_sequence_get_app ((ShellStartupSequence*)sequence);
|
app = shell_startup_sequence_get_app (sequence);
|
||||||
if (app)
|
if (app)
|
||||||
_shell_app_handle_startup_sequence (app, sequence);
|
_shell_app_handle_startup_sequence (app, sequence);
|
||||||
|
|
||||||
@@ -676,12 +669,13 @@ static void
|
|||||||
shell_window_tracker_init (ShellWindowTracker *self)
|
shell_window_tracker_init (ShellWindowTracker *self)
|
||||||
{
|
{
|
||||||
MetaDisplay *display = shell_global_get_display (shell_global_get ());
|
MetaDisplay *display = shell_global_get_display (shell_global_get ());
|
||||||
|
MetaStartupNotification *sn = meta_display_get_startup_notification (display);
|
||||||
|
|
||||||
self->window_to_app = g_hash_table_new_full (g_direct_hash, g_direct_equal,
|
self->window_to_app = g_hash_table_new_full (g_direct_hash, g_direct_equal,
|
||||||
NULL, (GDestroyNotify) g_object_unref);
|
NULL, (GDestroyNotify) g_object_unref);
|
||||||
|
|
||||||
|
|
||||||
g_signal_connect (display, "startup-sequence-changed",
|
g_signal_connect (sn, "changed",
|
||||||
G_CALLBACK (on_startup_sequence_changed), self);
|
G_CALLBACK (on_startup_sequence_changed), self);
|
||||||
|
|
||||||
load_initial_windows (self);
|
load_initial_windows (self);
|
||||||
@@ -792,60 +786,27 @@ on_focus_window_changed (MetaDisplay *display,
|
|||||||
* shell_window_tracker_get_startup_sequences:
|
* shell_window_tracker_get_startup_sequences:
|
||||||
* @tracker:
|
* @tracker:
|
||||||
*
|
*
|
||||||
* Returns: (transfer none) (element-type ShellStartupSequence): Currently active startup sequences
|
* Returns: (transfer none) (element-type MetaStartupSequence): Currently active startup sequences
|
||||||
*/
|
*/
|
||||||
GSList *
|
GSList *
|
||||||
shell_window_tracker_get_startup_sequences (ShellWindowTracker *self)
|
shell_window_tracker_get_startup_sequences (ShellWindowTracker *self)
|
||||||
{
|
{
|
||||||
ShellGlobal *global = shell_global_get ();
|
ShellGlobal *global = shell_global_get ();
|
||||||
MetaDisplay *display = shell_global_get_display (global);
|
MetaDisplay *display = shell_global_get_display (global);
|
||||||
|
MetaStartupNotification *sn = meta_display_get_startup_notification (display);
|
||||||
|
|
||||||
return meta_display_get_startup_sequences (display);
|
return meta_startup_notification_get_sequences (sn);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* sn_startup_sequence_ref returns void, so make a
|
static ShellApp *
|
||||||
* wrapper which returns self */
|
shell_startup_sequence_get_app (MetaStartupSequence *sequence)
|
||||||
static SnStartupSequence *
|
|
||||||
sequence_ref (SnStartupSequence *sequence)
|
|
||||||
{
|
|
||||||
sn_startup_sequence_ref (sequence);
|
|
||||||
return sequence;
|
|
||||||
}
|
|
||||||
|
|
||||||
GType
|
|
||||||
shell_startup_sequence_get_type (void)
|
|
||||||
{
|
|
||||||
static GType gtype = G_TYPE_INVALID;
|
|
||||||
if (gtype == G_TYPE_INVALID)
|
|
||||||
{
|
|
||||||
gtype = g_boxed_type_register_static ("ShellStartupSequence",
|
|
||||||
(GBoxedCopyFunc)sequence_ref,
|
|
||||||
(GBoxedFreeFunc)sn_startup_sequence_unref);
|
|
||||||
}
|
|
||||||
return gtype;
|
|
||||||
}
|
|
||||||
|
|
||||||
const char *
|
|
||||||
shell_startup_sequence_get_id (ShellStartupSequence *sequence)
|
|
||||||
{
|
|
||||||
return sn_startup_sequence_get_id ((SnStartupSequence*)sequence);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* shell_startup_sequence_get_app:
|
|
||||||
* @sequence: A #ShellStartupSequence
|
|
||||||
*
|
|
||||||
* Returns: (transfer none): The application being launched, or %NULL if unknown.
|
|
||||||
*/
|
|
||||||
ShellApp *
|
|
||||||
shell_startup_sequence_get_app (ShellStartupSequence *sequence)
|
|
||||||
{
|
{
|
||||||
const char *appid;
|
const char *appid;
|
||||||
char *basename;
|
char *basename;
|
||||||
ShellAppSystem *appsys;
|
ShellAppSystem *appsys;
|
||||||
ShellApp *app;
|
ShellApp *app;
|
||||||
|
|
||||||
appid = sn_startup_sequence_get_application_id ((SnStartupSequence*)sequence);
|
appid = meta_startup_sequence_get_application_id (sequence);
|
||||||
if (!appid)
|
if (!appid)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
@@ -856,61 +817,6 @@ shell_startup_sequence_get_app (ShellStartupSequence *sequence)
|
|||||||
return app;
|
return app;
|
||||||
}
|
}
|
||||||
|
|
||||||
const char *
|
|
||||||
shell_startup_sequence_get_name (ShellStartupSequence *sequence)
|
|
||||||
{
|
|
||||||
return sn_startup_sequence_get_name ((SnStartupSequence*)sequence);
|
|
||||||
}
|
|
||||||
|
|
||||||
gboolean
|
|
||||||
shell_startup_sequence_get_completed (ShellStartupSequence *sequence)
|
|
||||||
{
|
|
||||||
return sn_startup_sequence_get_completed ((SnStartupSequence*)sequence);
|
|
||||||
}
|
|
||||||
|
|
||||||
int
|
|
||||||
shell_startup_sequence_get_workspace (ShellStartupSequence *sequence)
|
|
||||||
{
|
|
||||||
return sn_startup_sequence_get_workspace ((SnStartupSequence*)sequence);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* shell_startup_sequence_create_icon:
|
|
||||||
* @sequence:
|
|
||||||
* @size: Size in pixels of icon
|
|
||||||
*
|
|
||||||
* Returns: (transfer none): A new #ClutterTexture containing an icon for the sequence
|
|
||||||
*/
|
|
||||||
ClutterActor *
|
|
||||||
shell_startup_sequence_create_icon (ShellStartupSequence *sequence, guint size)
|
|
||||||
{
|
|
||||||
GIcon *themed;
|
|
||||||
const char *icon_name;
|
|
||||||
ClutterActor *texture;
|
|
||||||
gint scale;
|
|
||||||
ShellGlobal *global;
|
|
||||||
StThemeContext *context;
|
|
||||||
|
|
||||||
global = shell_global_get ();
|
|
||||||
context = st_theme_context_get_for_stage (shell_global_get_stage (global));
|
|
||||||
g_object_get (context, "scale-factor", &scale, NULL);
|
|
||||||
|
|
||||||
icon_name = sn_startup_sequence_get_icon_name ((SnStartupSequence*)sequence);
|
|
||||||
if (!icon_name)
|
|
||||||
{
|
|
||||||
texture = clutter_texture_new ();
|
|
||||||
clutter_actor_set_size (texture, size * scale, size * scale);
|
|
||||||
return texture;
|
|
||||||
}
|
|
||||||
|
|
||||||
themed = g_themed_icon_new (icon_name);
|
|
||||||
texture = st_texture_cache_load_gicon (st_texture_cache_get_default (),
|
|
||||||
NULL, themed, size, scale);
|
|
||||||
g_object_unref (G_OBJECT (themed));
|
|
||||||
return texture;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_window_tracker_get_default:
|
* shell_window_tracker_get_default:
|
||||||
*
|
*
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
#include <glib-object.h>
|
#include <glib-object.h>
|
||||||
#include <glib.h>
|
#include <glib.h>
|
||||||
#include <meta/window.h>
|
#include <meta/window.h>
|
||||||
|
#include <meta/meta-startup-notification.h>
|
||||||
|
|
||||||
#include "shell-app.h"
|
#include "shell-app.h"
|
||||||
#include "shell-app-system.h"
|
#include "shell-app-system.h"
|
||||||
@@ -21,22 +22,8 @@ ShellApp *shell_window_tracker_get_window_app (ShellWindowTracker *tracker, Meta
|
|||||||
|
|
||||||
ShellApp *shell_window_tracker_get_app_from_pid (ShellWindowTracker *tracker, int pid);
|
ShellApp *shell_window_tracker_get_app_from_pid (ShellWindowTracker *tracker, int pid);
|
||||||
|
|
||||||
const char *_shell_window_tracker_get_app_context (ShellWindowTracker *tracker, ShellApp *app);
|
|
||||||
|
|
||||||
GSList *shell_window_tracker_get_startup_sequences (ShellWindowTracker *tracker);
|
GSList *shell_window_tracker_get_startup_sequences (ShellWindowTracker *tracker);
|
||||||
|
|
||||||
/* Hidden typedef for SnStartupSequence */
|
|
||||||
typedef struct _ShellStartupSequence ShellStartupSequence;
|
|
||||||
#define SHELL_TYPE_STARTUP_SEQUENCE (shell_startup_sequence_get_type ())
|
|
||||||
GType shell_startup_sequence_get_type (void);
|
|
||||||
|
|
||||||
const char *shell_startup_sequence_get_id (ShellStartupSequence *sequence);
|
|
||||||
ShellApp *shell_startup_sequence_get_app (ShellStartupSequence *sequence);
|
|
||||||
const char *shell_startup_sequence_get_name (ShellStartupSequence *sequence);
|
|
||||||
gboolean shell_startup_sequence_get_completed (ShellStartupSequence *sequence);
|
|
||||||
int shell_startup_sequence_get_workspace (ShellStartupSequence *sequence);
|
|
||||||
ClutterActor *shell_startup_sequence_create_icon (ShellStartupSequence *sequence, guint size);
|
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
#endif /* __SHELL_WINDOW_TRACKER_H__ */
|
#endif /* __SHELL_WINDOW_TRACKER_H__ */
|
||||||
|
@@ -248,14 +248,17 @@ st_button_touch_event (ClutterActor *actor,
|
|||||||
if (event->type == CLUTTER_TOUCH_BEGIN && !priv->press_sequence)
|
if (event->type == CLUTTER_TOUCH_BEGIN && !priv->press_sequence)
|
||||||
{
|
{
|
||||||
clutter_input_device_sequence_grab (device, sequence, actor);
|
clutter_input_device_sequence_grab (device, sequence, actor);
|
||||||
st_button_press (button, device, 0, sequence);
|
if (!clutter_event_is_pointer_emulated ((ClutterEvent*) event))
|
||||||
|
st_button_press (button, device, 0, sequence);
|
||||||
return CLUTTER_EVENT_STOP;
|
return CLUTTER_EVENT_STOP;
|
||||||
}
|
}
|
||||||
else if (event->type == CLUTTER_TOUCH_END &&
|
else if (event->type == CLUTTER_TOUCH_END &&
|
||||||
priv->device == device &&
|
priv->device == device &&
|
||||||
priv->press_sequence == sequence)
|
priv->press_sequence == sequence)
|
||||||
{
|
{
|
||||||
st_button_release (button, device, mask, 0, sequence);
|
if (!clutter_event_is_pointer_emulated ((ClutterEvent*) event))
|
||||||
|
st_button_release (button, device, mask, 0, sequence);
|
||||||
|
|
||||||
clutter_input_device_sequence_ungrab (device, sequence);
|
clutter_input_device_sequence_ungrab (device, sequence);
|
||||||
return CLUTTER_EVENT_STOP;
|
return CLUTTER_EVENT_STOP;
|
||||||
}
|
}
|
||||||
|
@@ -229,9 +229,9 @@ unpremultiply (ClutterColor *color)
|
|||||||
{
|
{
|
||||||
if (color->alpha != 0)
|
if (color->alpha != 0)
|
||||||
{
|
{
|
||||||
color->red = (color->red * 255 + 127) / color->alpha;
|
color->red = MIN((color->red * 255 + 127) / color->alpha, 255);
|
||||||
color->green = (color->green * 255 + 127) / color->alpha;
|
color->green = MIN((color->green * 255 + 127) / color->alpha, 255);
|
||||||
color->blue = (color->blue * 255 + 127) / color->alpha;
|
color->blue = MIN((color->blue * 255 + 127) / color->alpha, 255);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1414,6 +1414,32 @@ st_theme_node_load_background_image (StThemeNode *node)
|
|||||||
return node->background_texture != COGL_INVALID_HANDLE;
|
return node->background_texture != COGL_INVALID_HANDLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
st_theme_node_invalidate_resources_for_file (StThemeNode *node,
|
||||||
|
GFile *file)
|
||||||
|
{
|
||||||
|
StBorderImage *border_image;
|
||||||
|
gboolean changed = FALSE;
|
||||||
|
GFile *theme_file;
|
||||||
|
|
||||||
|
theme_file = st_theme_node_get_background_image (node);
|
||||||
|
if ((theme_file != NULL) && g_file_equal (theme_file, file))
|
||||||
|
{
|
||||||
|
st_theme_node_invalidate_background_image (node);
|
||||||
|
changed = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
border_image = st_theme_node_get_border_image (node);
|
||||||
|
theme_file = border_image ? st_border_image_get_file (border_image) : NULL;
|
||||||
|
if ((theme_file != NULL) && g_file_equal (theme_file, file))
|
||||||
|
{
|
||||||
|
st_theme_node_invalidate_border_image (node);
|
||||||
|
changed = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return changed;
|
||||||
|
}
|
||||||
|
|
||||||
static void st_theme_node_prerender_shadow (StThemeNodePaintState *state);
|
static void st_theme_node_prerender_shadow (StThemeNodePaintState *state);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@@ -2753,3 +2779,17 @@ st_theme_node_paint_state_invalidate (StThemeNodePaintState *state)
|
|||||||
state->alloc_width = 0;
|
state->alloc_width = 0;
|
||||||
state->alloc_height = 0;
|
state->alloc_height = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gboolean
|
||||||
|
st_theme_node_paint_state_invalidate_for_file (StThemeNodePaintState *state,
|
||||||
|
GFile *file)
|
||||||
|
{
|
||||||
|
if (state->node != NULL &&
|
||||||
|
st_theme_node_invalidate_resources_for_file (state->node, file))
|
||||||
|
{
|
||||||
|
st_theme_node_paint_state_invalidate (state);
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
@@ -291,6 +291,9 @@ void st_theme_node_paint_state_free (StThemeNodePaintState *state);
|
|||||||
void st_theme_node_paint_state_copy (StThemeNodePaintState *state,
|
void st_theme_node_paint_state_copy (StThemeNodePaintState *state,
|
||||||
StThemeNodePaintState *other);
|
StThemeNodePaintState *other);
|
||||||
void st_theme_node_paint_state_invalidate (StThemeNodePaintState *state);
|
void st_theme_node_paint_state_invalidate (StThemeNodePaintState *state);
|
||||||
|
gboolean st_theme_node_paint_state_invalidate_for_file (StThemeNodePaintState *state,
|
||||||
|
GFile *file);
|
||||||
|
|
||||||
void st_theme_node_paint_state_set_node (StThemeNodePaintState *state,
|
void st_theme_node_paint_state_set_node (StThemeNodePaintState *state,
|
||||||
StThemeNode *node);
|
StThemeNode *node);
|
||||||
|
|
||||||
|
@@ -289,44 +289,17 @@ st_widget_texture_cache_changed (StTextureCache *cache,
|
|||||||
{
|
{
|
||||||
StWidget *actor = ST_WIDGET (user_data);
|
StWidget *actor = ST_WIDGET (user_data);
|
||||||
StWidgetPrivate *priv = st_widget_get_instance_private (actor);
|
StWidgetPrivate *priv = st_widget_get_instance_private (actor);
|
||||||
StThemeNode *node = priv->theme_node;
|
|
||||||
StBorderImage *border_image;
|
|
||||||
gboolean changed = FALSE;
|
gboolean changed = FALSE;
|
||||||
GFile *theme_file;
|
int i;
|
||||||
|
|
||||||
if (node == NULL)
|
for (i = 0; i < G_N_ELEMENTS (priv->paint_states); i++)
|
||||||
return;
|
|
||||||
|
|
||||||
theme_file = st_theme_node_get_background_image (node);
|
|
||||||
if ((theme_file != NULL) && g_file_equal (theme_file, file))
|
|
||||||
{
|
{
|
||||||
st_theme_node_invalidate_background_image (node);
|
StThemeNodePaintState *paint_state = &priv->paint_states[i];
|
||||||
changed = TRUE;
|
changed |= st_theme_node_paint_state_invalidate_for_file (paint_state, file);
|
||||||
}
|
}
|
||||||
|
|
||||||
border_image = st_theme_node_get_border_image (node);
|
if (changed && clutter_actor_is_mapped (CLUTTER_ACTOR (actor)))
|
||||||
theme_file = border_image ? st_border_image_get_file (border_image) : NULL;
|
clutter_actor_queue_redraw (CLUTTER_ACTOR (actor));
|
||||||
if ((theme_file != NULL) && g_file_equal (theme_file, file))
|
|
||||||
{
|
|
||||||
st_theme_node_invalidate_border_image (node);
|
|
||||||
changed = TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (changed)
|
|
||||||
{
|
|
||||||
/* If we prerender the background / border, we need to update
|
|
||||||
* the paint state. We should probably implement a method to
|
|
||||||
* the theme node to determine this, but for now, just wipe
|
|
||||||
* the entire paint state.
|
|
||||||
*
|
|
||||||
* Use the existing state instead of a new one because it's
|
|
||||||
* assumed the rest of the state will stay the same.
|
|
||||||
*/
|
|
||||||
st_theme_node_paint_state_invalidate (current_paint_state (actor));
|
|
||||||
|
|
||||||
if (clutter_actor_is_mapped (CLUTTER_ACTOR (actor)))
|
|
||||||
clutter_actor_queue_redraw (CLUTTER_ACTOR (actor));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|