fix: 系统性修复类继承冲突 + 补全36+缺失导出

类继承冲突修复 (7个文件, 8组冲突):
- view_ext.py: 16个类继承view.py基础版本 (ViewOutlineProvider, ViewPropertyAnimator, ViewTreeObserver, ViewConfiguration, ViewParent, WindowInsets, Display, DragEvent, GestureDetector, ScaleGestureDetector, SoundEffectConstants, Surface, SurfaceView, TextureView, VelocityTracker, WindowInsetsController)
- hardware_sensor_ext.py: 3个类继承hardware.py (Sensor, SensorEvent, SensorEventListener)
- app_fragment.py: 3个类继承app.py (Fragment, FragmentManager, FragmentTransaction)
- content_intent.py: 3个类继承content.py/app.py (Intent, PendingIntent, IntentFilter)
- widget_ext.py: 29个类继承widget.py (18个单继承+11个多继承, 修复super()链)
- os_power.py: 2个类继承os.py (BatteryManager, PowerManager)
- net_ext.py: 12个类继承net.py (11个单继承+1个多继承)

__all__导出补全 (36个类):
- java.net: InterfaceAddress
- android.database: MatrixCursor, SQLiteStatement
- android.view: GestureDetector, ScaleGestureDetector, SurfaceHolder, Surface, SurfaceView, TextureView, ViewOutlineProvider, WindowManager, Window, LayoutInflater, Menu, MenuItem, ContextMenu, Display, DisplayMetrics
- android.graphics: Region, PathMeasure, NinePatch, Picture, PictureDrawable, Camera, PorterDuff, PorterDuffXfermode, Shader, LinearGradient, RadialGradient, SweepGradient, BitmapShader, ComposeShader, CornerPathEffect, DashPathEffect, PathDashPathEffect, SumPathEffect
- android.widget: LinearLayout, FrameLayout, RelativeLayout, TableLayout, TableRow, BaseAdapter, ArrayAdapter, SimpleAdapter, CursorAdapter, ImageButton, ToggleButton, RadioButton, SeekBar, RatingBar, ViewSwitcher, TextSwitcher, ImageSwitcher, SearchView, NumberPicker, Chronometer, TabHost, TabWidget, ViewAnimator, ZoomControls, DigitalClock, AnalogClock

统计: 221模块, 3666类, 31005方法, 183629行
This commit is contained in:
shuiyu1123 committed 2026-06-25 01:24:00 +00:00
1 parent fbb8263b13
commit 97d8b277d5
8 files changed
+205 -105

No files matched your search

+10 -7
View File
@@ -13,6 +13,9 @@ from typing import Any, Dict, List, Optional, Set, Tuple, Union
from .._core import Stub, AndroidOnlyError
from ..java.lang import RuntimeException
from .app import Intent as _BaseIntent
from .app import PendingIntent as _BasePendingIntent
from .content import IntentFilter as _BaseIntentFilter
IllegalArgumentException = type("IllegalArgumentException", (RuntimeException,), {})
@@ -680,8 +683,8 @@ MIME_TYPE_ALL = "*/*"
# Intent — 完整扩展
# ═══════════════════════════════════════════════════════════════
class Intent(Stub):
"""Android Intent — 完整扩展 (桌面存根)"""
class Intent(_BaseIntent):
"""Android Intent — 完整扩展 (桌面存根,继承 app.Intent 的所有方法)"""
# ── ShortcutIconResource inner class ──
@@ -1276,8 +1279,8 @@ class IntentReceiver(Stub):
# PendingIntent
# ═══════════════════════════════════════════════════════════════
class PendingIntent(Stub):
"""PendingIntent — 延迟 Intent"""
class PendingIntent(_BasePendingIntent):
"""PendingIntent — 延迟 Intent (继承 app.PendingIntent 的所有方法)"""
FLAG_ONE_SHOT = 1 << 30
FLAG_NO_CREATE = 1 << 29
@@ -1288,7 +1291,7 @@ class PendingIntent(Stub):
def __init__(self, intent: Optional[Intent] = None, requestCode: int = 0,
flags: int = 0):
super().__init__()
super().__init__(intent, requestCode, flags)
self._intent = intent
self._request_code = requestCode
self._flags = flags
@@ -1475,8 +1478,8 @@ class IntentService(Stub):
# IntentFilter
# ═══════════════════════════════════════════════════════════════
class IntentFilter(Stub):
"""IntentFilter — Intent 过滤器 (桌面存根)"""
class IntentFilter(_BaseIntentFilter):
"""IntentFilter — Intent 过滤器 (桌面存根,继承 content.IntentFilter 的所有方法)"""
class AuthorityEntry(Stub):
"""AuthorityEntry — 权限条目"""